Class: Noder::HTTP::Listeners::Request

Inherits:
Events::Listeners::Base show all
Defined in:
lib/noder/http/listeners/request.rb

Instance Attribute Summary

Attributes inherited from Events::Listeners::Base

#callback

Instance Method Summary collapse

Methods inherited from Events::Listeners::Base

#initialize

Constructor Details

This class inherits a constructor from Noder::Events::Listeners::Base

Instance Method Details

#call(env) ⇒ Object



5
6
7
8
9
# File 'lib/noder/http/listeners/request.rb', line 5

def call(env)
  env[:request] ||= Noder::HTTP::Request.new(env[:request_env])
  callback.call(env) if callback
  env
end