mirror of
https://github.com/krau/SaveAny-Bot.git
synced 2026-09-04 15:16:37 +08:00
fix: replace nil ctx to context.Background
This commit is contained in:
+2
-1
@@ -1,6 +1,7 @@
|
|||||||
package api
|
package api
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"context"
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
@@ -195,6 +196,6 @@ func (t *TaskProgressInfo) Emit(e taskevent.Event) {
|
|||||||
|
|
||||||
if notify {
|
if notify {
|
||||||
payload := CreateWebhookPayload(t.TaskID, t.Type, t.Status, t.Storage, t.Path, e.Err)
|
payload := CreateWebhookPayload(t.TaskID, t.Type, t.Status, t.Storage, t.Path, e.Err)
|
||||||
SendWebhook(nil, payload)
|
SendWebhook(context.Background(), payload)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user