diff options
author | Ilkka Oksanen <iao@iki.fi> | 2018-06-29 12:41:34 +0200 |
---|---|---|
committer | Ilkka Oksanen <iao@iki.fi> | 2018-08-20 13:35:35 +0200 |
commit | e385e4678fc64be6e176c3bdac6641db9fe48d85 (patch) | |
tree | 3bffbc828977cbae12a2f902b0c6226b4a3bf6da /actionpack | |
parent | 3e3a0d1cc31ff929de2b27f2e6790d2ccdde9e2c (diff) | |
download | rails-e385e4678fc64be6e176c3bdac6641db9fe48d85.tar.gz rails-e385e4678fc64be6e176c3bdac6641db9fe48d85.tar.bz2 rails-e385e4678fc64be6e176c3bdac6641db9fe48d85.zip |
Don't handle params option in a special way in url_for helper
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/CHANGELOG.md | 4 | ||||
-rw-r--r-- | actionpack/lib/action_dispatch/routing/route_set.rb | 4 | ||||
-rw-r--r-- | actionpack/test/controller/base_test.rb | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/actionpack/CHANGELOG.md b/actionpack/CHANGELOG.md index a30f178190..0d6e6941ea 100644 --- a/actionpack/CHANGELOG.md +++ b/actionpack/CHANGELOG.md @@ -1,3 +1,7 @@ +* Remove undocumented `params` option from `url_from` helper + + *Ilkka Oksanen* + * Purpose metadata for signed/encrypted cookies. Rails can now thwart attacks that attempt to copy signed/encrypted value diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb index 07d3a41173..233c9ff244 100644 --- a/actionpack/lib/action_dispatch/routing/route_set.rb +++ b/actionpack/lib/action_dispatch/routing/route_set.rb @@ -820,10 +820,6 @@ module ActionDispatch path, params = generate(route_name, path_options, recall) - if options.key? :params - params.merge! options[:params] - end - options[:path] = path options[:script_name] = script_name options[:params] = params diff --git a/actionpack/test/controller/base_test.rb b/actionpack/test/controller/base_test.rb index a672ede1a9..907de44bdb 100644 --- a/actionpack/test/controller/base_test.rb +++ b/actionpack/test/controller/base_test.rb @@ -193,7 +193,7 @@ class UrlOptionsTest < ActionController::TestCase action: "home", controller: "pages", only_path: true, - params: { "token" => "secret" } + token: "secret" } assert_equal "/home?token=secret", rs.url_for(options) |