Browse files

Merge pull request #2512 from arunagw/cant_dup_on_nil_3-1-stable

Cant dup on nil 3 1 stable
  • Loading branch information...
2 parents d9d78d4 + d761ec4 commit 5b6ac344ff1143b089dff6b3f961840c5076ab28 @spastorino spastorino committed Aug 12, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 actionpack/lib/action_dispatch/routing/url_for.rb
View
2 actionpack/lib/action_dispatch/routing/url_for.rb
@@ -140,7 +140,7 @@ def url_for(options = nil)
when String
options
when nil, Hash
- _routes.url_for((options.dup || {}).reverse_merge!(url_options).symbolize_keys)
+ _routes.url_for((options || {}).reverse_merge(url_options).symbolize_keys)
else
polymorphic_url(options)
end

0 comments on commit 5b6ac34

Please sign in to comment.