lib/async/http/protocol/http1/server.rb in async-http-0.64.0 vs lib/async/http/protocol/http1/server.rb in async-http-0.64.1
- old
+ new
@@ -48,11 +48,11 @@
while request = next_request
response = yield(request, self)
body = response&.body
- if @stream.nil? and body.nil?
- # Full hijack.
+ if hijacked?
+ body&.close
return
end
task.defer_stop do
# If a response was generated, send it: