lib/hashie_mappy.rb in hashie_mappy-0.3.0 vs lib/hashie_mappy.rb in hashie_mappy-0.4.0

- old
+ new

@@ -2,11 +2,11 @@ require "active_support/core_ext/hash" module HashieMappy attr_accessor :target_map, :output, :after - ALLOWED_TYPES = [Fixnum, String, Float, Bignum] + ALLOWED_TYPES = [Integer, String, Float] def self.extended(base) base.class_eval do self.target_map = nil end @@ -20,9 +20,10 @@ self.after = block end def normalize(input_hash) input_hash = convert_to_hash(input_hash) unless input_hash.is_a?(Hash) + input_hash.deep_stringify_keys! output = normalize_hash(self.target_map, input_hash) if input_hash.keys.any? output = after.call(input_hash, output) if after output.with_indifferent_access end \ No newline at end of file