Skip to content
Browse files

Merge pull request #16352 from gchan/remove-unnecessary-convert-key

Removed unnecessary call to 'convert_key' in 'HashWithIndifferentAccess#to_hash'
  • Loading branch information...
2 parents 5d4fce6 + d952a7a commit dc9a6825be5421277d70d9f76da80297674e5da1 @carlosantoniodasilva carlosantoniodasilva committed
Showing with 2 additions and 2 deletions.
  1. +2 −2 activesupport/lib/active_support/hash_with_indifferent_access.rb
View
4 activesupport/lib/active_support/hash_with_indifferent_access.rb
@@ -246,9 +246,9 @@ def reject(*args, &block)
# Convert to a regular hash with string keys.
def to_hash
- _new_hash= {}
+ _new_hash = {}
each do |key, value|
- _new_hash[convert_key(key)] = convert_value(value, for: :to_hash)
+ _new_hash[key] = convert_value(value, for: :to_hash)
end
Hash.new(default).merge!(_new_hash)
end

0 comments on commit dc9a682

Please sign in to comment.
Something went wrong with that request. Please try again.