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

feat(Webhook): addition of Webhook#avatarURL function #3625

Merged
merged 5 commits into from
Dec 15, 2019
Merged

feat(Webhook): addition of Webhook#avatarURL function #3625

merged 5 commits into from
Dec 15, 2019

Conversation

Fyko
Copy link
Contributor

@Fyko Fyko commented Dec 15, 2019

Please describe the changes this PR makes and why it should be merged:
This PR adds support for a Webhook#avatarURL function. Although not documented, a webhook's avatar follows the same format as a users.

I tested this with the following code in my eval command:

(async () => {
  const webhook = await msg.channel.fetchWebhooks().then(h => h.first());
  return this.client.rest.cdn.Avatar(webhook.id, webhook.avatar);
})()

Status

  • Code changes have been tested against the Discord API, or there are no code changes
  • I know how to update typings and have done so, or typings don't need updating

Semantic versioning classification:

  • This PR changes the library's interface (methods or parameters added)
    • This PR includes breaking changes (methods removed or renamed, parameters moved or removed)
  • This PR only includes non-code changes, like changes to documentation, README, etc.

@SpaceEEC SpaceEEC merged commit 330d5db into discordjs:master Dec 15, 2019
SpaceEEC added a commit to SpaceEEC/discord.js that referenced this pull request Jan 18, 2020
SpaceEEC added a commit that referenced this pull request Jan 24, 2020
* feat(Webhook): add avatarURL getter

This backports: #3625

* feat(Webhook): add type, createAt, and createdTimestamp

This backports: #3585

* feat(Webhook): add url getter

This backports: #3178

* docs(Webhook): add missing type and readonly tags
@Fyko Fyko deleted the patch-2 branch February 7, 2020 00:12
samsamson33 pushed a commit to samsamson33/discord.js that referenced this pull request Feb 27, 2020
* feat: addition of Webhook#avatarURL

* typings: added Webhook#avatarURL

* fix: trailing space

* docs: fixed jsdoc function description

* fix: typo
samsamson33 added a commit to samsamson33/discord.js that referenced this pull request Feb 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants