fix!: return Webhook struct from WebhookEdit and WebhookEditWithToken (#1497)

This commit is contained in:
Cyb3r Jak3 2024-02-16 09:06:04 -05:00 committed by GitHub
parent 7f80bc7978
commit 15ef2a43d4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -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"`