diff options
author | Gannon McGibbon <gannon.mcgibbon@gmail.com> | 2018-10-29 13:45:26 -0400 |
---|---|---|
committer | Gannon McGibbon <gannon.mcgibbon@gmail.com> | 2018-11-13 18:05:05 -0500 |
commit | 6b3faf8e502dbd238fe4b4c409e96308638297a1 (patch) | |
tree | e3257a024cdc9cacf79f4d6e38b4531ecca38da9 /actionpack/lib/action_dispatch/http/filter_parameters.rb | |
parent | 0b75743e345f98d3f53f5a29fcd0e91d2a370a24 (diff) | |
download | rails-6b3faf8e502dbd238fe4b4c409e96308638297a1.tar.gz rails-6b3faf8e502dbd238fe4b4c409e96308638297a1.tar.bz2 rails-6b3faf8e502dbd238fe4b4c409e96308638297a1.zip |
Allow rescue from parameter parse errors
[Gannon McGibbon + Josh Cheek]
Diffstat (limited to 'actionpack/lib/action_dispatch/http/filter_parameters.rb')
-rw-r--r-- | actionpack/lib/action_dispatch/http/filter_parameters.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/http/filter_parameters.rb b/actionpack/lib/action_dispatch/http/filter_parameters.rb index 9f8f178402..cbb772175c 100644 --- a/actionpack/lib/action_dispatch/http/filter_parameters.rb +++ b/actionpack/lib/action_dispatch/http/filter_parameters.rb @@ -41,6 +41,8 @@ module ActionDispatch # Returns a hash of parameters with all sensitive data replaced. def filtered_parameters @filtered_parameters ||= parameter_filter.filter(parameters) + rescue ActionDispatch::Http::Parameters::ParseError + @filtered_parameters = {} end # Returns a hash of request.env with all sensitive data replaced. |