Skip to content

Commit

Permalink
server/requestlog: make responseStats implement http.Flusher (#3275)
Browse files Browse the repository at this point in the history
  • Loading branch information
vangent committed Jul 19, 2023
1 parent 8cab06e commit a1d9f42
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions server/requestlog/requestlog.go
Original file line number Diff line number Diff line change
Expand Up @@ -233,3 +233,9 @@ func (r *responseStats) Hijack() (_ net.Conn, _ *bufio.ReadWriter, err error) {
}
return nil, nil, errors.New("underlying ResponseWriter does not support hijacking")
}

func (r *responseStats) Flush() {
if fl, ok := r.w.(http.Flusher); ok {
fl.Flush()
}
}

0 comments on commit a1d9f42

Please sign in to comment.