Method: Hash#to_mash

Defined in:
lib/extlib/hash.rb

#to_mashMash

Convert to Mash. This class has semantics of ActiveSupport’s HashWithIndifferentAccess and we only have it so that people can write params instead of params.

Returns:

  • (Mash)

    This hash as a Mash for string or symbol key access.



94
95
96
97
98
# File 'lib/extlib/hash.rb', line 94

def to_mash
  hash = Mash.new(self)
  hash.default = default
  hash
end