Module: DeviseAuthProxy

Defined in:
lib/devise_auth_proxy.rb,
lib/devise_auth_proxy/helper.rb,
lib/devise_auth_proxy/manager.rb,
lib/devise_auth_proxy/version.rb

Defined Under Namespace

Modules: Helper Classes: Error, Manager

Constant Summary collapse

VERSION =
"0.2.3"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.attribute_mapObject

Returns the value of attribute attribute_map.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def attribute_map
  @attribute_map
end

.auth_keyObject

Returns the value of attribute auth_key.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def auth_key
  @auth_key
end

.auto_createObject

Returns the value of attribute auto_create.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def auto_create
  @auto_create
end

.auto_updateObject

Returns the value of attribute auto_update.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def auto_update
  @auto_update
end

.default_roleObject

Returns the value of attribute default_role.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def default_role
  @default_role
end

.env_keyObject

Returns the value of attribute env_key.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def env_key
  @env_key
end

Returns the value of attribute http_cookie.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def http_cookie
  @http_cookie
end

.logout_serviceObject

Returns the value of attribute logout_service.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def logout_service
  @logout_service
end

.logout_urlObject

Returns the value of attribute logout_url.



6
7
8
# File 'lib/devise_auth_proxy.rb', line 6

def logout_url
  @logout_url
end

Class Method Details

.configure {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:



41
42
43
# File 'lib/devise_auth_proxy.rb', line 41

def self.configure
  yield self
end

.proxy_user_id(env) ⇒ Object



45
46
47
48
49
50
51
52
# File 'lib/devise_auth_proxy.rb', line 45

def self.proxy_user_id(env)
  case env_key
  when Proc
    env_key.call(env)
  else
    env[env_key]
  end
end