diff --git a/botfilter.go b/botfilter.go index 853d9d1e..1c5b2a90 100644 --- a/botfilter.go +++ b/botfilter.go @@ -105,3 +105,11 @@ type statusRecorder struct { status int } +func (r *statusRecorder) WriteHeader(status int) { + if r.status != 0 { + return + } + r.status = status + r.ResponseWriter.WriteHeader(status) +} +