Class: Hash

Inherits:
Object
  • Object
show all
Defined in:
lib/docify/utils.rb

Instance Method Summary collapse

Instance Method Details

#stringify_keysObject



10
11
12
# File 'lib/docify/utils.rb', line 10

def stringify_keys
  dup.stringify_keys!
end

#stringify_keys!Object



3
4
5
6
7
8
# File 'lib/docify/utils.rb', line 3

def stringify_keys!
  keys.each do |key|
    self[key.to_s] = delete(key)
  end
  self
end