lib/io_streams/tabular/parser/hash.rb in iostreams-1.1.0 vs lib/io_streams/tabular/parser/hash.rb in iostreams-1.1.1

- old
+ new

@@ -1,13 +1,11 @@ -require 'json' +require "json" module IOStreams class Tabular module Parser class Hash < Base def parse(row) - unless row.is_a?(::Hash) - raise(IOStreams::Errors::TypeMismatch, "Format is :hash. Invalid input: #{row.class.name}") - end + raise(IOStreams::Errors::TypeMismatch, "Format is :hash. Invalid input: #{row.class.name}") unless row.is_a?(::Hash) row end def render(row, header)