feat(botfilter): add statusRecorder.Write

This commit is contained in:
hoelee committed 2026-06-09 16:47:00 +08:00
1 parent 53c288d46e
commit eb4d3ec627
1 file changed
+7
+7
View File
@@ -113,3 +113,10 @@ func (r *statusRecorder) WriteHeader(status int) {
r.ResponseWriter.WriteHeader(status)
}
func (r *statusRecorder) Write(data []byte) (int, error) {
if r.status == 0 {
r.status = http.StatusOK
}
return r.ResponseWriter.Write(data)
}