Class: ActionController::Filters::ClassMethods::ProcFilter

Inherits:
Filter
  • Object
show all
Defined in:
lib/action_controller/filters.rb

Overview

:nodoc:

Instance Attribute Summary

Attributes inherited from Filter

#excluded_actions, #filter, #included_actions

Instance Method Summary collapse

Methods inherited from Filter

#after?, #around?, #before?, #initialize

Constructor Details

This class inherits a constructor from ActionController::Filters::ClassMethods::Filter

Instance Method Details

#call(controller) ⇒ Object



461
462
463
464
465
# File 'lib/action_controller/filters.rb', line 461

def call(controller)
  @filter.call(controller)
rescue LocalJumpError # a yield from a proc... no no bad dog.
  raise(ActionControllerError, 'Cannot yield from a Proc type filter. The Proc must take two arguments and execute #call on the second argument.')
end