lib/cascade/helpers/hash.rb in cascade-rb-0.1.4 vs lib/cascade/helpers/hash.rb in cascade-rb-0.1.5
- old
+ new
@@ -1,5 +1,9 @@
class Hash
- def reverse_merge(other_hash)
- other_hash.merge(self)
+ unless Hash.instance_methods.include? :reverse_merge
+ # Merges the caller into +other_hash+
+ #
+ def reverse_merge(other_hash)
+ other_hash.merge(self)
+ end
end
end