lib/cotton_tail/queue/reader.rb in cotton-tail-0.3.0 vs lib/cotton_tail/queue/reader.rb in cotton-tail-0.4.0
- old
+ new
@@ -26,15 +26,19 @@
end
private
def call_next
- args = fiber.resume
- middleware.call([@app, *args]) if args
+ request = fiber.resume
+ middleware.call([env, request, Response.new]) if request
end
def middleware
@app.config.middleware
+ end
+
+ def env
+ @app.env
end
end
end
end