Module: ScrubParams::Parameters
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/scrub_params/parameters.rb
Instance Method Summary collapse
Instance Method Details
#scrub ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/scrub_params/parameters.rb', line 9 def scrub self.scrubbed_keys = [] hash = {} each_pair do |k, v| hash[k] = scrub_value(k, v) end if scrubbed_keys.any? ActiveSupport::Notifications.instrument("scrubbed_parameters.action_controller", keys: scrubbed_keys.uniq) end hash end |