Class: Warden::Cognito::LocalUserMapper

Inherits:
Object
  • Object
show all
Defined in:
lib/warden/cognito/local_user_mapper.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.find(token_decoder) ⇒ Object



7
8
9
# File 'lib/warden/cognito/local_user_mapper.rb', line 7

def find(token_decoder)
  new.call(token_decoder)
end

.find_by_token(token) ⇒ Object



11
12
13
# File 'lib/warden/cognito/local_user_mapper.rb', line 11

def find_by_token(token)
  find(TokenDecoder.new(token))
end

Instance Method Details

#call(token_decoder) ⇒ Object



16
17
18
# File 'lib/warden/cognito/local_user_mapper.rb', line 16

def call(token_decoder)
  helper.find_by_cognito_attribute local_identifier(token_decoder), token_decoder.pool_identifier
end