Class: Errordite::Rack
- Inherits:
-
Object
- Object
- Errordite::Rack
- Defined in:
- lib/errordite/rack.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app, options = {}) ⇒ Rack
constructor
A new instance of Rack.
Constructor Details
#initialize(app, options = {}) ⇒ Rack
5 6 7 8 |
# File 'lib/errordite/rack.rb', line 5 def initialize(app, = {}) @app = app @context = [:context] || {} end |
Instance Method Details
#call(env) ⇒ Object
10 11 12 13 14 |
# File 'lib/errordite/rack.rb', line 10 def call(env) Errordite.monitor rack_context(env).merge(@context) do @app.call(env) end end |