aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillermo Iguaran <guilleiguaran@gmail.com>2013-01-20 09:34:42 -0800
committerGuillermo Iguaran <guilleiguaran@gmail.com>2013-01-20 09:34:42 -0800
commit74c2af5b91248565d0bd8174aec3f0737b79535c (patch)
tree299ec6f8c0360b113bff24d83b628976411ec10d
parentcbec22ce5783c9530b3e2735a8e13eeeca00e0d2 (diff)
parent53ea940c5b7ba907f89747c6b959374f635c9a39 (diff)
downloadrails-74c2af5b91248565d0bd8174aec3f0737b79535c.tar.gz
rails-74c2af5b91248565d0bd8174aec3f0737b79535c.tar.bz2
rails-74c2af5b91248565d0bd8174aec3f0737b79535c.zip
Merge pull request #9004 from arunagw/warning_removed_shadowing_outer
Removing warning: shadowing outer local variable
-rw-r--r--actionpack/lib/action_controller/metal/strong_parameters.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/lib/action_controller/metal/strong_parameters.rb b/actionpack/lib/action_controller/metal/strong_parameters.rb
index 02d9c0b4fb..e03777b5bb 100644
--- a/actionpack/lib/action_controller/metal/strong_parameters.rb
+++ b/actionpack/lib/action_controller/metal/strong_parameters.rb
@@ -382,9 +382,9 @@ module ActionController
params[key] = self[key]
end
- keys.grep(/\A#{Regexp.escape(key)}\(\d+[if]?\)\z/).each do |key|
- if permitted_scalar?(self[key])
- params[key] = self[key]
+ keys.grep(/\A#{Regexp.escape(key)}\(\d+[if]?\)\z/).each do |k|
+ if permitted_scalar?(self[k])
+ params[k] = self[k]
end
end
end