Module: Auth::Behavior::Core::ControllerExtensions::ClassMethods

Defined in:
lib/auth/behavior/core/controller_extensions/class_methods.rb

Instance Method Summary collapse

Instance Method Details

#require_login(*args) ⇒ Object Also known as: requires_login, require_user, requires_user



10
11
12
# File 'lib/auth/behavior/core/controller_extensions/class_methods.rb', line 10

def (*args)
  before_filter :require_login, *args
end

#require_login_for(*actions) ⇒ Object



2
3
4
# File 'lib/auth/behavior/core/controller_extensions/class_methods.rb', line 2

def (*actions)
  before_filter :require_login, actions.extract_options!.merge(:only => actions)
end

#require_logout(*args) ⇒ Object Also known as: requires_logout, require_no_user, requires_no_user



14
15
16
# File 'lib/auth/behavior/core/controller_extensions/class_methods.rb', line 14

def require_logout(*args)
  before_filter :require_logout, *args
end

#require_logout_for(*actions) ⇒ Object



6
7
8
# File 'lib/auth/behavior/core/controller_extensions/class_methods.rb', line 6

def require_logout_for(*actions)
  before_filter :require_logout, actions.extract_options!.merge(:only => actions)
end