mirror of
https://github.com/danbulant/discord.js
synced 2026-06-19 14:41:36 +00:00
Webpack build: edfb27f428
This commit is contained in:
parent
464ede757d
commit
db4b457175
2 changed files with 18 additions and 4 deletions
|
|
@ -165,7 +165,8 @@ const Endpoints = exports.Endpoints = {
|
|||
// guilds
|
||||
guilds: `${API}/guilds`,
|
||||
guild: (guildID) => `${Endpoints.guilds}/${guildID}`,
|
||||
guildIcon: (guildID, hash) => `${Endpoints.guild(guildID)}/icons/${hash}.jpg`,
|
||||
guildIcon: (guildID, hash) => `${Endpoints.CDN}/icons/${guildID}/${hash}.jpg`,
|
||||
guildSplash: (guildID, hash) => `${Endpoints.CDN}/splashes/${guildID}/${hash}.jpg`,
|
||||
guildPrune: (guildID) => `${Endpoints.guild(guildID)}/prune`,
|
||||
guildEmbed: (guildID) => `${Endpoints.guild(guildID)}/embed`,
|
||||
guildInvites: (guildID) => `${Endpoints.guild(guildID)}/invites`,
|
||||
|
|
@ -206,6 +207,9 @@ const Endpoints = exports.Endpoints = {
|
|||
// oauth
|
||||
myApplication: `${API}/oauth2/applications/@me`,
|
||||
getApp: (id) => `${API}/oauth2/authorize?client_id=${id}`,
|
||||
|
||||
// emoji
|
||||
emoji: (emojiID) => `${Endpoints.CDN}/emojis/${emojiID}.png`,
|
||||
};
|
||||
|
||||
exports.Status = {
|
||||
|
|
@ -1775,7 +1779,7 @@ class Emoji {
|
|||
* @readonly
|
||||
*/
|
||||
get url() {
|
||||
return `${Constants.Endpoints.CDN}/emojis/${this.id}.png`;
|
||||
return Constants.Endpoints.emoji(this.id);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -5559,6 +5563,16 @@ class Guild {
|
|||
return Constants.Endpoints.guildIcon(this.id, this.icon);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the URL to this guild's splash (if it has one, otherwise it returns null)
|
||||
* @type {?string}
|
||||
* @readonly
|
||||
*/
|
||||
get splashURL() {
|
||||
if (!this.splash) return null;
|
||||
return Constants.Endpoints.guildSplash(this.id, this.splash);
|
||||
}
|
||||
|
||||
/**
|
||||
* The owner of the guild
|
||||
* @type {GuildMember}
|
||||
|
|
|
|||
4
discord.indev.min.js
vendored
4
discord.indev.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue