Sha256: 1ced6b069284c2b43d5397093800aaf67dbaf636bd5bfa062c6a311cfd883a66
Contents?: true
Size: 413 Bytes
Versions: 14
Compression:
Stored size: 413 Bytes
Contents
module Chronicle module ETL module Utils module HashUtilities def self.flatten_hash(hash) hash.each_with_object({}) do |(k, v), h| if v.is_a? Hash flatten_hash(v).map do |h_k, h_v| h["#{k}.#{h_k}".to_sym] = h_v end else h[k] = v end end end end end end end
Version data entries
14 entries across 14 versions & 1 rubygems