Class: Hash
- Inherits:
-
Object
- Object
- Hash
- Defined in:
- lib/mark_facets/ruby/hash.rb
Instance Method Summary collapse
Instance Method Details
#to_mash ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'lib/mark_facets/ruby/hash.rb', line 4 def to_mash h = self.dup h.each do |k, v| if v.is_a?(Hash) && !v.is_a?(Hashie::Mash) h[k] = v.to_mash end end Hashie::Mash.new(h) end |