Class: MiniAuth::ResetGuardMiddleware

Inherits:
Object
  • Object
show all
Defined in:
lib/mini_auth/reset_guard_middleware.rb

Instance Method Summary collapse

Constructor Details

#initialize(app) ⇒ ResetGuardMiddleware

Returns a new instance of ResetGuardMiddleware.



5
6
7
# File 'lib/mini_auth/reset_guard_middleware.rb', line 5

def initialize(app)
  @app = app
end

Instance Method Details

#call(env) ⇒ Object



9
10
11
12
13
# File 'lib/mini_auth/reset_guard_middleware.rb', line 9

def call(env)
  @app.call(env)
ensure
  MiniAuth::AuthManager.instance.reset_guards!
end