MCPcopy
hub / github.com/labstack/echo / WriteHeader

Method WriteHeader

middleware/compress.go:147–154  ·  view source on GitHub ↗
(code int)

Source from the content-addressed store, hash-verified

145}
146
147func (w *gzipResponseWriter) WriteHeader(code int) {
148 w.Header().Del(echo.HeaderContentLength) // Issue #444
149
150 w.wroteHeader = true
151
152 // Delay writing of the header until we know if we'll actually compress the response
153 w.code = code
154}
155
156func (w *gzipResponseWriter) Write(b []byte) (int, error) {
157 if w.Header().Get(echo.HeaderContentType) == "" {

Callers 9

ToMiddlewareMethod · 0.45
WriteMethod · 0.45
FlushMethod · 0.45
TestProxyRetriesFunction · 0.45
TestProxyErrorHandlerFunction · 0.45

Calls 1

HeaderMethod · 0.45