Class: Doorkeeper::OAuth::Hooks::Context
- Inherits:
-
Object
- Object
- Doorkeeper::OAuth::Hooks::Context
- Defined in:
- lib/doorkeeper/oauth/hooks/context.rb
Instance Attribute Summary collapse
-
#auth ⇒ Object
readonly
Returns the value of attribute auth.
-
#pre_auth ⇒ Object
readonly
Returns the value of attribute pre_auth.
Instance Method Summary collapse
-
#initialize(**attributes) ⇒ Context
constructor
A new instance of Context.
- #issued_token ⇒ Object
Constructor Details
#initialize(**attributes) ⇒ Context
Returns a new instance of Context.
9 10 11 12 13 |
# File 'lib/doorkeeper/oauth/hooks/context.rb', line 9 def initialize(**attributes) attributes.each do |name, value| instance_variable_set(:"@#{name}", value) if respond_to?(name) end end |
Instance Attribute Details
#auth ⇒ Object (readonly)
Returns the value of attribute auth.
7 8 9 |
# File 'lib/doorkeeper/oauth/hooks/context.rb', line 7 def auth @auth end |
#pre_auth ⇒ Object (readonly)
Returns the value of attribute pre_auth.
7 8 9 |
# File 'lib/doorkeeper/oauth/hooks/context.rb', line 7 def pre_auth @pre_auth end |
Instance Method Details
#issued_token ⇒ Object
15 16 17 |
# File 'lib/doorkeeper/oauth/hooks/context.rb', line 15 def issued_token auth&.issued_token end |