Class: Hash

Inherits:
Object
  • Object
show all
Defined in:
lib/strife/core_ext/hash.rb

Instance Method Summary collapse

Instance Method Details

#reverse_merge(other) ⇒ Object



2
3
4
# File 'lib/strife/core_ext/hash.rb', line 2

def reverse_merge(other)
  other.merge(self)
end

#reverse_merge!(other) ⇒ Object



6
7
8
# File 'lib/strife/core_ext/hash.rb', line 6

def reverse_merge!(other)
  merge!(other) { |key, left, right| left }
end