Class: Hash

Inherits:
Object show all
Defined in:
lib/jenkins/core_ext/object/blank.rb,
lib/jenkins/core_ext/hash.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#with_clean_keysObject



2
3
4
5
6
7
8
# File 'lib/jenkins/core_ext/hash.rb', line 2

def with_clean_keys
  self.inject({}) do |mem, (key, value)|
    clean_key = key.to_s.gsub(/-/,"_").to_sym
    mem[clean_key] = value
    mem
  end
end