Sha256: 78b6bba187a6ac11ed315685ddce8edae758406f4cd0cc6c71a60feff0d6cc4d
Contents?: true
Size: 447 Bytes
Versions: 2
Compression:
Stored size: 447 Bytes
Contents
# encoding: utf-8 # module Mode module Sdk # Provides simple utility methods for manipulating a Hash # module HashUtil # Stringify hash keys # # @param hash [Hash] the original hash # # @return [Hash] a new hash with string keys # def stringify_keys(hash) hash.each_with_object({}) do |(key, value), result| result[key.to_s] = value end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mode-sdk-0.1.0 | lib/mode/sdk/hash_util.rb |
mode-sdk-0.0.1 | lib/mode/sdk/hash_util.rb |