Exception: OmniAuth::Strategies::OAuth2::CallbackError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/omniauth/strategies/oauth2.rb

Overview

An error that is indicated in the OAuth 2.0 callback. This could be a ‘redirect_uri_mismatch` or other

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(error, error_reason = nil, error_uri = nil) ⇒ CallbackError

Returns a new instance of CallbackError.



117
118
119
120
121
# File 'lib/omniauth/strategies/oauth2.rb', line 117

def initialize(error, error_reason = nil, error_uri = nil)
  self.error = error
  self.error_reason = error_reason
  self.error_uri = error_uri
end

Instance Attribute Details

#errorObject

Returns the value of attribute error.



115
116
117
# File 'lib/omniauth/strategies/oauth2.rb', line 115

def error
  @error
end

#error_reasonObject

Returns the value of attribute error_reason.



115
116
117
# File 'lib/omniauth/strategies/oauth2.rb', line 115

def error_reason
  @error_reason
end

#error_uriObject

Returns the value of attribute error_uri.



115
116
117
# File 'lib/omniauth/strategies/oauth2.rb', line 115

def error_uri
  @error_uri
end

Instance Method Details

#messageObject



123
124
125
# File 'lib/omniauth/strategies/oauth2.rb', line 123

def message
  [error, error_reason, error_uri].compact.join(' | ')
end