Method: Dry::Transformer::HashTransformations.map_values
- Defined in:
- lib/dry/transformer/hash_transformations.rb
.map_values(source_hash, fn) ⇒ Hash
Map all values in a hash using transformation function
143 144 145 |
# File 'lib/dry/transformer/hash_transformations.rb', line 143 def self.map_values(source_hash, fn) Hash[source_hash].transform_values!(&fn) end |