debian-mirror-gitlab/workhorse/internal/helper/nginx/nginx.go

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
279 B
Go
Raw Normal View History

2023-03-04 22:38:38 +05:30
package nginx
import "net/http"
const ResponseBufferHeader = "X-Accel-Buffering"
func DisableResponseBuffering(w http.ResponseWriter) {
w.Header().Set(ResponseBufferHeader, "no")
}
func AllowResponseBuffering(w http.ResponseWriter) {
w.Header().Del(ResponseBufferHeader)
}