Class: Puma::Configuration::ConfigMiddleware
- Inherits:
-
Object
- Object
- Puma::Configuration::ConfigMiddleware
- Defined in:
- lib/puma/configuration.rb
Overview
Injects the Configuration object into the env
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(config, app) ⇒ ConfigMiddleware
constructor
A new instance of ConfigMiddleware.
Constructor Details
#initialize(config, app) ⇒ ConfigMiddleware
Returns a new instance of ConfigMiddleware.
242 243 244 245 |
# File 'lib/puma/configuration.rb', line 242 def initialize(config, app) @config = config @app = app end |
Instance Method Details
#call(env) ⇒ Object
247 248 249 250 |
# File 'lib/puma/configuration.rb', line 247 def call(env) env[Const::PUMA_CONFIG] = @config @app.call(env) end |