Module: Authlogic::Session::Scopes::InstanceMethods

Defined in:
lib/authlogic/session/scopes.rb

Instance Method Summary collapse

Instance Method Details

#initialize_with_scopes(*args) ⇒ Object

:nodoc:



83
84
85
86
# File 'lib/authlogic/session/scopes.rb', line 83

def initialize_with_scopes(*args) # :nodoc:
  self.scope = self.class.scope
  initialize_without_scopes(*args)
end

#scopeObject

See the documentation for this class for more information on how to use this method.



89
90
91
# File 'lib/authlogic/session/scopes.rb', line 89

def scope
  @scope ||= {}
end

#search_for_record_with_scopes(*args) ⇒ Object

:nodoc:



93
94
95
96
97
# File 'lib/authlogic/session/scopes.rb', line 93

def search_for_record_with_scopes(*args) # :nodoc:
  klass.send(:with_scope, :find => (scope[:find_options] || {})) do
    search_for_record_without_scopes(*args)
  end
end