Module: Rad::ControllerRoutingHelper::ClassMethods

Defined in:
lib/rad/web/_router/controller_routing_helper.rb

Instance Method Summary collapse

Instance Method Details

#persist_params(*args) ⇒ Object

persist_params controller filters



9
10
11
12
13
14
15
16
17
# File 'lib/rad/web/_router/controller_routing_helper.rb', line 9

def persist_params *args
  if args.empty?
    before :persist_params
  elsif args.first.is_a? Hash
    before :persist_params, args.first
  else
    before :persist_params, only: args.first
  end
end