This commit is contained in:
robbix1206 2017-08-19 19:36:29 +02:00 committed by Chris Rhodes
parent 3c8a0dd940
commit d6b616c58f

View file

@ -1863,14 +1863,9 @@ func (s *Session) WebhookEditWithToken(webhookID, token, name, avatar string) (s
// WebhookDelete deletes a webhook for a given ID
// webhookID: The ID of a webhook.
func (s *Session) WebhookDelete(webhookID string) (st *Webhook, err error) {
func (s *Session) WebhookDelete(webhookID string) (err error) {
body, err := s.RequestWithBucketID("DELETE", EndpointWebhook(webhookID), nil, EndpointWebhooks)
if err != nil {
return
}
err = unmarshal(body, &st)
_, err = s.RequestWithBucketID("DELETE", EndpointWebhook(webhookID), nil, EndpointWebhooks)
return
}