mirror of
https://github.com/labstack/echo.git
synced 2025-01-01 22:09:21 +02:00
proxy middleware should use http proxy for SSE requests (#2624)
This commit is contained in:
parent
3062025405
commit
e0f2a02e4c
@ -366,8 +366,7 @@ func ProxyWithConfig(config ProxyConfig) echo.MiddlewareFunc {
|
||||
switch {
|
||||
case c.IsWebSocket():
|
||||
proxyRaw(tgt, c).ServeHTTP(res, req)
|
||||
case req.Header.Get(echo.HeaderAccept) == "text/event-stream":
|
||||
default:
|
||||
default: // even SSE requests
|
||||
proxyHTTP(tgt, c, config).ServeHTTP(res, req)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user