The HTTP state (@hs) object could be replaced in proxy_wait_next
causing @hs.env['rack.logger'] to become inaccessible.
---
lib/yahns/proxy_http_response.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/yahns/proxy_http_response.rb b/lib/yahns/proxy_http_response.rb
index a37b387..74f5ce5 100644
--- a/lib/yahns/proxy_http_response.rb
+++ b/lib/yahns/proxy_http_response.rb
@@ -46,7 +46,7 @@ def proxy_write(wbuf, buf, req_res)
end
def proxy_err_response(code, req_res, exc)
- logger = @hs.env['rack.logger']
+ logger = self.class.logger # Yahns::HttpContext#logger
case exc
when nil
logger.error('premature upstream EOF')
--
EW
--
unsubscribe: [email protected]
archive: https://yhbt.net/yahns-public/