aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_controller/routing.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/lib/action_controller/routing.rb')
-rw-r--r--actionpack/lib/action_controller/routing.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/routing.rb b/actionpack/lib/action_controller/routing.rb
index a806b995c0..f97956d040 100644
--- a/actionpack/lib/action_controller/routing.rb
+++ b/actionpack/lib/action_controller/routing.rb
@@ -214,11 +214,10 @@ module ActionController
options = options.symbolize_keys
defaults = request.path_parameters.symbolize_keys
+ options = defaults if options.empty? # Get back the current url if no options was passed
expand_controller_path!(options, defaults)
defaults.delete_if {|k, v| options.key?(k) && options[k].nil?} # Remove defaults that have been manually cleared using :name => nil
- options = defaults if options.empty? # Get back the current url if no options was passed
-
failures = []
selected = nil
self.each do |route|