lundi 26 août 2019

Rails 3.2.x: how to filter long parameters from getting logged using ActionController action?

There are similar questions like this, this, and this.

None help because the goal is to prevent logging of long parameters within a specific action instead of using config.filter_parameters. Also the answer must work for Rails 3.2.x while many answers are based on Rails 5.

One answer suggests calling request.filtered_parameters inside the controller method, but calling request.filtered_parameters.delete :long_param did not stop :log_param from getting logged.

Aucun commentaire:

Enregistrer un commentaire