Permalink
Browse files

Merge pull request #26895 from yui-knk/use_same_class_on_transform_va…

…lues

Ensure `#transform_values` of HWIDA to return HWIDA
  • Loading branch information...
guilleiguaran authored and matthewd committed Oct 26, 2016
1 parent 1ca08ba commit c49e5989ac77a9921ab890d68355362b24890958
Showing with 5 additions and 0 deletions.
  1. +5 −0 activesupport/lib/active_support/hash_with_indifferent_access.rb
@@ -274,6 +274,11 @@ def reject(*args, &block)
dup.tap { |hash| hash.reject!(*args, &block) }
end
def transform_values(*args, &block)
return to_enum(:transform_values) unless block_given?
dup.tap { |hash| hash.transform_values!(*args, &block) }
end
# Convert to a regular hash with string keys.
def to_hash
_new_hash = Hash.new

0 comments on commit c49e598

Please sign in to comment.