class Shamu::Rack::QueryParamsMiddleware
Expose a {QueryParams} hash to any service that wants to toggle behavior based on query parameters.
Public Class Methods
new( app )
click to toggle source
# File lib/shamu/rack/query_params_middleware.rb, line 11 def initialize( app ) @app = app end
Public Instance Methods
call( env )
click to toggle source
# File lib/shamu/rack/query_params_middleware.rb, line 15 def call( env ) query_params = Shamu::Rack::QueryParams.new( env ) scorpion( env ).hunt_for Shamu::Rack::QueryParams, return: query_params @app.call( env ) end