Class: Rack::OAuth2::Server::Rails::Authorize

Inherits:
Authorize show all
Defined in:
lib/rack/oauth2/server/rails/authorize.rb

Defined Under Namespace

Modules: ResponseExt

Instance Attribute Summary

Attributes inherited from Abstract::Handler

#authenticator, #request, #response

Instance Method Summary collapse

Methods inherited from Abstract::Handler

#call

Constructor Details

#initialize(app) ⇒ Authorize

Returns a new instance of Authorize.



6
7
8
9
# File 'lib/rack/oauth2/server/rails/authorize.rb', line 6

def initialize(app)
  super()
  @app = app
end

Instance Method Details

#_call(env) ⇒ Object



11
12
13
14
15
16
# File 'lib/rack/oauth2/server/rails/authorize.rb', line 11

def _call(env)
  prepare_oauth_env env
  @app.call env
rescue Rack::OAuth2::Server::Abstract::Error => e
  e.finish
end