-
-
Notifications
You must be signed in to change notification settings - Fork 458
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: webhooks not sending attachment info #2513
base: master
Are you sure you want to change the base?
Conversation
@@ -644,8 +644,9 @@ def handle_message_parameters( | |||
payload["embeds"] = [] if embed is None else [embed.to_dict()] | |||
if content is not MISSING: | |||
payload["content"] = str(content) if content is not None else None | |||
attachments = [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes the line below obsolete
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
then += instead? it needs to be defined outside the if
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you intended to create a new variable, but this one overshadows the parameter with the same name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or it needs to be put in an else after the if
Summary
This adds
attachments
to the multipart payload sent in webhooks, which previously didn't exist. This only impacteddescription
, but necessary to implement nonetheless.I HOPE this doesn't break anything, but further testing with editing attachments would be appreciated.
Information
examples, ...).
Checklist
type: ignore
comments were used, a comment is also left explaining why.