Class: AnyLogger::Example::RackLogger
- Inherits:
-
Object
- Object
- AnyLogger::Example::RackLogger
- Defined in:
- lib/any_logger/example/rack_logger.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app) ⇒ RackLogger
constructor
A new instance of RackLogger.
Constructor Details
#initialize(app) ⇒ RackLogger
Returns a new instance of RackLogger.
6 7 8 |
# File 'lib/any_logger/example/rack_logger.rb', line 6 def initialize(app) @app = app end |
Instance Method Details
#call(env) ⇒ Object
10 11 12 13 14 |
# File 'lib/any_logger/example/rack_logger.rb', line 10 def call(env) @app.call(env) ensure ActiveSupport::LogSubscriber.flush_all! end |