Skip to content
This repository was archived by the owner on Mar 5, 2023. It is now read-only.

Commit 1f2f1d9

Browse files
author
jonas747
committed
fix using incorrect bucket for webhooks
1 parent c9fe514 commit 1f2f1d9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

restapi.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2189,7 +2189,7 @@ func (s *Session) WebhookExecute(webhookID int64, token string, wait bool, data
21892189
uri += "?wait=true"
21902190
}
21912191

2192-
_, err = s.RequestWithBucketID("POST", uri, data, EndpointWebhookToken(0, ""))
2192+
_, err = s.RequestWithBucketID("POST", uri, data, EndpointWebhookToken(webhookID, token))
21932193

21942194
return
21952195
}
@@ -2262,9 +2262,9 @@ func (s *Session) WebhookExecuteComplex(webhookID int64, token string, wait bool
22622262
return
22632263
}
22642264

2265-
response, err = s.request("POST", endpoint, bodywriter.FormDataContentType(), body.Bytes(), EndpointWebhookToken(0, ""))
2265+
response, err = s.request("POST", endpoint, bodywriter.FormDataContentType(), body.Bytes(), EndpointWebhookToken(webhookID, token))
22662266
} else {
2267-
response, err = s.RequestWithBucketID("POST", endpoint, data, EndpointWebhookToken(0, ""))
2267+
response, err = s.RequestWithBucketID("POST", endpoint, data, EndpointWebhookToken(webhookID, token))
22682268
}
22692269

22702270
if err != nil {

0 commit comments

Comments
 (0)