class Hash

Public Instance Methods

rename_keys(keys_replacement_hash) click to toggle source
# File lib/mtk_framework/core_extensions/hash/rename_keys.rb, line 4
def rename_keys(keys_replacement_hash)
  transform_keys do |key|
    next key unless keys_replacement_hash.key?(key)

    keys_replacement_hash[key]
  end
end