Overview

Defined Under Namespace

Class Method Details

.included(klass) ⇒ Object

29
30
31
32
33
34
35
36
37

# File 'lib/authlogic/acts_as_authentic/logged_in_status.rb', line 29defself.included(klass)returnif!klass.column_names.include?("last_request_at")klass.class_evaldoincludeInstanceMethodsscope:logged_in,lambda{where("last_request_at > ? and current_login_at IS NOT NULL",logged_in_timeout.seconds.ago)}scope:logged_out,lambda{where("last_request_at is NULL or last_request_at <= ?",logged_in_timeout.seconds.ago)}endend