Sha256: e70886a3ca6cce8c7f38cf904edc0ea3af0ee7954283f099cd416ae1c62ee320
Contents?: true
Size: 315 Bytes
Versions: 17
Compression:
Stored size: 315 Bytes
Contents
class Hash alias :+ :merge def -(thing_to_be_deleted) if thing_to_be_deleted.is_a? Hash thing_to_be_deleted.each do |key, value| self.delete(key) if self[key] == value end elsif self.keys.include? thing_to_be_deleted self.delete(thing_to_be_deleted) end self end end
Version data entries
17 entries across 17 versions & 7 rubygems