Skip to content
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: allow null to be passed in order to reset icon/avatar #6646

Merged
merged 3 commits into from Sep 23, 2021

Conversation

iShibi
Copy link
Contributor

@iShibi iShibi commented Sep 15, 2021

Please describe the changes this PR makes and why it should be merged:

This PR updates documentation and typings to allow null as a valid value for icon/avatar of a Guild, ClientUser, and Webhook.

It also fixes a bug in ClientUser#edit and Guild#edit where the icon option wasn't being resolved, making it impossible to set a new icon using a path to the local file.

⚠️ From the docs for Modify Guild Docs, it seems that splash, discovery_splash, and banner can also be set to null. My test guild doesn't have those features, so I didn't add changes related to them here. It would be great if someone can confirm it.

Status and versioning classification:

  • Code changes have been tested against the Discord API
  • I know how to update typings and have done so

@vladfrangu
Copy link
Member

⚠️ From the docs for Modify Guild Docs, it seems that splash, discovery_splash, and banner can also be set to null. My test guild doesn't have those features, so I didn't add changes related to them here. It would be great if someone can confirm it.

You're correct on that assumption

@iCrawl iCrawl merged commit 6033506 into discordjs:main Sep 23, 2021
@iShibi iShibi deleted the doc-null branch January 12, 2022 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants