Sha256: 392c21e951ba397f2bfdcd5214a60bf36840bd9c3f94674d9f0d13594980a51f
Contents?: true
Size: 312 Bytes
Versions: 4
Compression:
Stored size: 312 Bytes
Contents
# frozen_string_literal: true module Dotcrypt::CoreExt::Hash refine Hash do def deep_stringify_keys to_h { |k, v| [k.to_s, v.is_a?(Hash) ? v.deep_stringify_keys : v] } end def deep_symbolize_keys to_h { |k, v| [k.to_sym, v.is_a?(Hash) ? v.deep_symbolize_keys : v] } end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
dotcrypt-0.2.0 | lib/dotcrypt/core_ext/hash.rb |
dotcrypt-0.1.3 | lib/dotcrypt/core_ext/hash.rb |
dotcrypt-0.1.2 | lib/dotcrypt/core_ext/hash.rb |
dotcrypt-0.1.0 | lib/dotcrypt/core_ext/hash.rb |