diff options
author | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2012-11-19 21:27:47 -0200 |
---|---|---|
committer | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2012-11-19 21:43:48 -0200 |
commit | ce60672342f8da447d24d25f8c0f2049fc81c0c8 (patch) | |
tree | aab5c1f759ebc4f94025d42911223f697e6d327e /actionpack/lib/action_dispatch/http | |
parent | e492c446d520e8941624564b157b297cfd0aeaa9 (diff) | |
download | rails-ce60672342f8da447d24d25f8c0f2049fc81c0c8.tar.gz rails-ce60672342f8da447d24d25f8c0f2049fc81c0c8.tar.bz2 rails-ce60672342f8da447d24d25f8c0f2049fc81c0c8.zip |
Correct the use of params options when given to url_for
Merge url for tests and add changelog entry for #8233.
Diffstat (limited to 'actionpack/lib/action_dispatch/http')
-rw-r--r-- | actionpack/lib/action_dispatch/http/url.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/http/url.rb b/actionpack/lib/action_dispatch/http/url.rb index 7183939934..bced7d84c0 100644 --- a/actionpack/lib/action_dispatch/http/url.rb +++ b/actionpack/lib/action_dispatch/http/url.rb @@ -28,7 +28,7 @@ module ActionDispatch path = options.delete(:script_name).to_s.chomp("/") path << options.delete(:path).to_s - params = options[:params].is_a?(Hash) ? options[:params] : {} + params = options[:params].is_a?(Hash) ? options[:params] : options.slice(:params) params.reject! { |_,v| v.to_param.nil? } result = build_host_url(options) |