fix: close resp body

This commit is contained in:
guangwu
2024-04-24 16:16:24 +08:00
committed by guangwu
parent 6f798c0664
commit 0442c5512f
+1
View File
@@ -133,6 +133,7 @@ func sendWebhook(url string) (string, []error) {
// the reloader seems to retry automatically so no retry logic added
return "", err
}
defer resp.Body.Close()
var buffer bytes.Buffer
_, bufferErr := io.Copy(&buffer, resp.Body)
if bufferErr != nil {