Class: Registrar::Adapter::OmniAuth::AuthNormalizer

Inherits:
Object
  • Object
show all
Defined in:
lib/registrar/adapter/omni_auth.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(auth) ⇒ AuthNormalizer

Returns a new instance of AuthNormalizer


26
27
28
# File 'lib/registrar/adapter/omni_auth.rb', line 26

def initialize(auth)
  @auth = auth
end

Class Method Details

.normalized(auth) ⇒ Object


22
23
24
# File 'lib/registrar/adapter/omni_auth.rb', line 22

def self.normalized(auth)
  new(auth).normalize
end

Instance Method Details

#normalizeObject


30
31
32
33
34
35
# File 'lib/registrar/adapter/omni_auth.rb', line 30

def normalize
  normalized = {}
  normalized['provider'] = normalize_provider
  normalized['profile'] = normalize_profile
  normalized
end