Class: Oauth2CallbackFilter
- Inherits:
-
Object
- Object
- Oauth2CallbackFilter
- Defined in:
- lib/oauth2_callback_filter.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app) ⇒ Oauth2CallbackFilter
constructor
A new instance of Oauth2CallbackFilter.
Constructor Details
#initialize(app) ⇒ Oauth2CallbackFilter
Returns a new instance of Oauth2CallbackFilter.
2 3 4 |
# File 'lib/oauth2_callback_filter.rb', line 2 def initialize(app) @app = app end |
Instance Method Details
#call(env) ⇒ Object
6 7 8 9 10 11 |
# File 'lib/oauth2_callback_filter.rb', line 6 def call(env) unless env["rack.session"][:oauth2_callback_method].blank? env["REQUEST_METHOD"] = env["rack.session"].delete(:oauth2_callback_method).to_s.upcase end @app.call(env) end |