lib/net/ftp/list/unix.rb in net-ftp-list-0.3 vs lib/net/ftp/list/unix.rb in net-ftp-list-0.4
- old
+ new
@@ -36,19 +36,19 @@
def initialize(raw)
super(raw)
match = REGEXP.match(raw.strip) or raise ParserError
case match[1]
- when /d/ then self.dir = true
- when /l/ then self.symlink = true
- when /[f-]/ then self.file = true
+ when /d/ then @dir = true
+ when /l/ then @symlink = true
+ when /[f-]/ then @file = true
when /[bc]/ then # Do nothing with devices for now.
else ParserError 'Unknown LIST entry type.'
end
# TODO: Permissions, users, groups, date/time.
- self.basename = match[21].match(/^(.+)(?:\s+\->.+)?$/)[0].strip
+ @basename = match[21].match(/^(.+)(?:\s+\->.+)?$/)[0].strip
end
end
end
end
\ No newline at end of file