From 15ef2a43d47f9b00bf28d84d7b0a3dc183a5723e Mon Sep 17 00:00:00 2001 From: Cyb3r Jak3 Date: Fri, 16 Feb 2024 09:06:04 -0500 Subject: [PATCH] fix!: return Webhook struct from WebhookEdit and WebhookEditWithToken (#1497) --- restapi.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/restapi.go b/restapi.go index ea5ded3..3aec73c 100644 --- a/restapi.go +++ b/restapi.go @@ -2270,7 +2270,7 @@ func (s *Session) WebhookWithToken(webhookID, token string, options ...RequestOp // webhookID: The ID of a webhook. // name : The name of the webhook. // avatar : The avatar of the webhook. -func (s *Session) WebhookEdit(webhookID, name, avatar, channelID string, options ...RequestOption) (st *Role, err error) { +func (s *Session) WebhookEdit(webhookID, name, avatar, channelID string, options ...RequestOption) (st *Webhook, err error) { data := struct { Name string `json:"name,omitempty"` @@ -2293,7 +2293,7 @@ func (s *Session) WebhookEdit(webhookID, name, avatar, channelID string, options // token : The auth token for the webhook. // name : The name of the webhook. // avatar : The avatar of the webhook. -func (s *Session) WebhookEditWithToken(webhookID, token, name, avatar string, options ...RequestOption) (st *Role, err error) { +func (s *Session) WebhookEditWithToken(webhookID, token, name, avatar string, options ...RequestOption) (st *Webhook, err error) { data := struct { Name string `json:"name,omitempty"`