mirror of
https://github.com/caddyserver/caddy.git
synced 2026-05-25 00:46:07 -04:00
proxy: recognize client's cancellation
fix issue #1589 Signed-off-by: Tw <tw19881113@gmail.com>
This commit is contained in:
@@ -2,7 +2,6 @@ package httpserver
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
"errors"
|
||||
"net"
|
||||
"net/http"
|
||||
"time"
|
||||
@@ -103,7 +102,7 @@ func (r *ResponseRecorder) Push(target string, opts *http.PushOptions) error {
|
||||
return pusher.Push(target, opts)
|
||||
}
|
||||
|
||||
return errors.New("push is unavailable (probably chained http.ResponseWriter does not implement http.Pusher)")
|
||||
return NonPusherError{Underlying: r.ResponseWriter}
|
||||
}
|
||||
|
||||
// Interface guards
|
||||
|
||||
Reference in New Issue
Block a user