Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed :overwrite_param so it doesn't delete but reject elements from …

…@request.parameters #982 [raphinou@yahoo.com]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1061 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 5d42774b6253dabeb8238651422a113be1bfe083 1 parent 00121b2
@dhh dhh authored
View
2  actionpack/CHANGELOG
@@ -1,5 +1,7 @@
*SVN*
+* Fixed :overwrite_param so it doesn't delete but reject elements from @request.parameters #982 [raphinou@yahoo.com]
+
* Added :method option to verify for ensuring that either GET, POST, etc is allowed #984 [Jamis Buck]
* Added options to set cc, bcc, subject, and body for UrlHelper#mail_to #966 [DeLynn]
View
2  actionpack/lib/action_controller/url_rewriter.rb
@@ -38,7 +38,7 @@ def rewrite_path(options)
path, extras = Routing::Routes.generate(options, @request)
if extras[:overwrite_params]
- params_copy = @request.parameters.delete_if { |k,v| ["controller","action"].include? k }
+ params_copy = @request.parameters.reject { |k,v| ["controller","action"].include? k }
params_copy.update extras[:overwrite_params]
extras.delete(:overwrite_params)
extras.update(params_copy)
Please sign in to comment.
Something went wrong with that request. Please try again.