Exception: Rack::OAuth2::Server::OAuthError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/rack/oauth2/server/errors.rb

Overview

Base class for all OAuth errors. These map to error codes in the spec.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code, message) ⇒ OAuthError

Returns a new instance of OAuthError.



8
9
10
11
# File 'lib/rack/oauth2/server/errors.rb', line 8

def initialize(code, message)
  super message
  @code = code.to_sym
end

Instance Attribute Details

#codeObject (readonly)

The OAuth error code.



14
15
16
# File 'lib/rack/oauth2/server/errors.rb', line 14

def code
  @code
end