class Hash

Monkey patch for diff method

Public Instance Methods

diff(other) click to toggle source
# File lib/hash.rb, line 4
def diff(other)
  self.keys.inject({}) do |memo, key|
    unless self[key] == other[key]
      memo[key] = [self[key], other[key]]
    end
    memo
  end
end