Commit 262db103307d31b0fc00080f00e9a25273a4c1d3
1 parent
af47f58d
Exists in
master
and in
1 other branch
Rubocop: manually fix shadowing of outer variable
Fixes: $ rubocop --lint --only ShadowingOuterLocalVariable
Showing
1 changed file
with
3 additions
and
3 deletions
Show diff stats
app/models/notice.rb
... | ... | @@ -136,9 +136,9 @@ class Notice |
136 | 136 | end |
137 | 137 | end |
138 | 138 | |
139 | - def sanitize_hash(h) | |
140 | - h.recurse do |h| | |
141 | - h.inject({}) do |h,(k,v)| | |
139 | + def sanitize_hash(hash) | |
140 | + hash.recurse do |recurse_hash| | |
141 | + recurse_hash.inject({}) do |h,(k,v)| | |
142 | 142 | if k.is_a?(String) |
143 | 143 | h[k.gsub(/\./,'.').gsub(/^\$/,'$')] = v |
144 | 144 | else | ... | ... |