MCPcopy
hub / github.com/go-chi/chi / basicWriter

Struct basicWriter

middleware/wrap_writer.go:73–80  ·  view source on GitHub ↗

basicWriter wraps a http.ResponseWriter that implements the minimal http.ResponseWriter interface.

Source from the content-addressed store, hash-verified

71// basicWriter wraps a http.ResponseWriter that implements the minimal
72// http.ResponseWriter interface.
73type basicWriter struct {
74 http.ResponseWriter
75 tee io.Writer
76 code int
77 bytes int
78 wroteHeader bool
79 discard bool
80}
81
82func (b *basicWriter) WriteHeader(code int) {
83 if code >= 100 && code <= 199 && code != http.StatusSwitchingProtocols {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected