aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2011-12-08 21:16:12 +0100
committerJosé Valim <jose.valim@gmail.com>2011-12-08 21:20:47 +0100
commitc41f08cefe6fa3747ee79001d9c88dc988e8064d (patch)
tree8b1da87300d21cac47141a5834eb9cde3660fc62 /actionpack/lib/action_dispatch
parent5da90b34831a0f941b36edbede9089c54432ad6b (diff)
downloadrails-c41f08cefe6fa3747ee79001d9c88dc988e8064d.tar.gz
rails-c41f08cefe6fa3747ee79001d9c88dc988e8064d.tar.bz2
rails-c41f08cefe6fa3747ee79001d9c88dc988e8064d.zip
Move symbolize keys to the inner options as we can assume url_options will be properly symbolized.
Diffstat (limited to 'actionpack/lib/action_dispatch')
-rw-r--r--actionpack/lib/action_dispatch/routing/route_set.rb2
-rw-r--r--actionpack/lib/action_dispatch/routing/url_for.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb
index c64214431a..6d6de36a08 100644
--- a/actionpack/lib/action_dispatch/routing/route_set.rb
+++ b/actionpack/lib/action_dispatch/routing/route_set.rb
@@ -557,7 +557,7 @@ module ActionDispatch
path_addition, params = generate(path_options, path_segments || {})
path << path_addition
- ActionDispatch::Http::URL.url_for(options.merge({
+ ActionDispatch::Http::URL.url_for(options.merge!({
:path => path,
:params => params,
:user => user,
diff --git a/actionpack/lib/action_dispatch/routing/url_for.rb b/actionpack/lib/action_dispatch/routing/url_for.rb
index 39ba83fb9a..22e41c9c16 100644
--- a/actionpack/lib/action_dispatch/routing/url_for.rb
+++ b/actionpack/lib/action_dispatch/routing/url_for.rb
@@ -145,7 +145,7 @@ module ActionDispatch
when String
options
when nil, Hash
- _routes.url_for((options || {}).reverse_merge(url_options).symbolize_keys)
+ _routes.url_for((options || {}).symbolize_keys.reverse_merge!(url_options))
else
polymorphic_url(options)
end