Class: Limbo::Rails::ParameterFilter

Inherits:
Object
  • Object
show all
Defined in:
lib/limbo/rails/parameter_filter.rb

Class Method Summary collapse

Class Method Details

.filter(hash) ⇒ Object



4
5
6
7
8
9
10
11
# File 'lib/limbo/rails/parameter_filter.rb', line 4

def self.filter(hash)
  if hash.is_a?(Hash)
    filter = ::Rails.application.config.filter_parameters
    ActionDispatch::Http::ParameterFilter.new(filter).filter(hash)
  else
    hash
  end
end