lib/masticate/base.rb in masticate-0.3.1 vs lib/masticate/base.rb in masticate-0.3.2
- old
+ new
@@ -68,14 +68,14 @@
while line = get
row = CSV.parse_line(line, csv_options) #.map {|s| s && s.strip}
if row
row = row.map {|s| s && s.strip}
end
- # row2 = row.map {|s| s && s.strip}
- # if row2.nil?
- # puts "**** ROW IS [#{row.inspect}]"
- # end
- output = crunch(row)
+ if self.class == Masticate::Mender
+ output = crunch(row, line, csv_options)
+ else
+ output = crunch(row)
+ end
emit(output) if output
end
end
crunch(nil) {|row| emit(row)}
@output.close if opts[:output]