lib/async/http/protocol/http1/server.rb in async-http-0.52.5 vs lib/async/http/protocol/http1/server.rb in async-http-0.53.0
- old
+ new
@@ -78,10 +78,10 @@
# We also don't want to hold on to the response object:
response = nil
body.call(stream)
- elsif body and request.connect?
+ elsif request.connect? and response.success?
stream = write_tunnel_body(request.version)
# Same as above:
request = nil
response = nil