Module: TrickBag::CoreTypes

Defined in:
lib/trick_bag/core_types/core_types.rb

Class Method Summary collapse

Class Method Details

.clone_hash_except(source_hash, keys_to_delete) ⇒ Object



6
7
8
9
10
# File 'lib/trick_bag/core_types/core_types.rb', line 6

def clone_hash_except(source_hash, keys_to_delete)
  new_hash = source_hash.clone
  keys_to_delete.each { |key| new_hash.delete(key) }
  new_hash
end