Sha256: 43e668da973c02bbd0645d12a64de489971994705a9a4c749380660709a18b8e

Contents?: true

Size: 287 Bytes

Versions: 9

Compression:

Stored size: 287 Bytes

Contents

unless Hash.method_defined?(:symbolize_keys)
  class Hash
    def symbolize_keys
      inject({}){|h, (k, v)| h[k.to_sym] = v; h}
    end
  end
end

unless Hash.method_defined?(:reverse_merge!)
  class Hash
    def reverse_merge!(other)
      replace other.merge(self)
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
google-apis-0.2.0 lib/google_apis/core_ext/hash.rb
google-apis-0.1.7 lib/google_apis/core_ext/hash.rb
google-apis-0.1.6 lib/google_apis/core_ext/hash.rb
google-apis-0.1.5 lib/google_apis/core_ext/hash.rb
google-apis-0.1.4 lib/google_apis/core_ext/hash.rb
google-apis-0.1.3 lib/google_apis/core_ext/hash.rb
google-apis-0.1.2 lib/google_apis/core_ext/hash.rb
google-apis-0.1.1 lib/google_apis/core_ext/hash.rb
google-apis-0.1.0 lib/google_apis/core_ext/hash.rb