Method: Chop::Diff#field

Defined in:
lib/chop/diff.rb

#field(key) ⇒ Object



95
96
97
98
99
100
101
# File 'lib/chop/diff.rb', line 95

def field key
  hash_transformation do |hashes|
    hashes.map! do |row|
      row.merge key => yield(row[key])
    end
  end
end