Class: NimbleAuth::AuthenticationService

Inherits:
Object
  • Object
show all
Defined in:
app/services/nimble_auth/authentication_service.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(auth_params: {}, auth_type: nil) ⇒ AuthenticationService

Returns a new instance of AuthenticationService.



7
8
9
10
# File 'app/services/nimble_auth/authentication_service.rb', line 7

def initialize(auth_params: {}, auth_type: nil)
  @auth_params = auth_params.deep_symbolize_keys
  @auth_type = auth_type
end

Instance Attribute Details

#auth_paramsObject (readonly)

Returns the value of attribute auth_params.



5
6
7
# File 'app/services/nimble_auth/authentication_service.rb', line 5

def auth_params
  @auth_params
end

#auth_typeObject (readonly)

Returns the value of attribute auth_type.



5
6
7
# File 'app/services/nimble_auth/authentication_service.rb', line 5

def auth_type
  @auth_type
end

Instance Method Details

#callObject



12
13
14
# File 'app/services/nimble_auth/authentication_service.rb', line 12

def call
  auth_klass.new(auth_params).call
end