From ba9537c275d5434aff505cdc5d435009715dcc0e Mon Sep 17 00:00:00 2001 From: Dmitrii Golub Date: Wed, 28 Mar 2012 03:09:40 +0400 Subject: remove redundant variable --- activesupport/lib/active_support/core_ext/hash/deep_dup.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/activesupport/lib/active_support/core_ext/hash/deep_dup.rb b/activesupport/lib/active_support/core_ext/hash/deep_dup.rb index 447142605c..9ab179c566 100644 --- a/activesupport/lib/active_support/core_ext/hash/deep_dup.rb +++ b/activesupport/lib/active_support/core_ext/hash/deep_dup.rb @@ -3,8 +3,7 @@ class Hash def deep_dup duplicate = self.dup duplicate.each_pair do |k,v| - tv = duplicate[k] - duplicate[k] = tv.is_a?(Hash) && v.is_a?(Hash) ? tv.deep_dup : v + duplicate[k] = v.is_a?(Hash) ? v.deep_dup : v end duplicate end -- cgit v1.2.3