mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-18 12:33:30 +01:00
check guild availability when aggregating client emojis (#1711)
This commit is contained in:
@@ -245,7 +245,7 @@ class Client extends EventEmitter {
|
|||||||
get emojis() {
|
get emojis() {
|
||||||
const emojis = new Collection();
|
const emojis = new Collection();
|
||||||
for (const guild of this.guilds.values()) {
|
for (const guild of this.guilds.values()) {
|
||||||
for (const emoji of guild.emojis.values()) emojis.set(emoji.id, emoji);
|
if (guild.available) for (const emoji of guild.emojis.values()) emojis.set(emoji.id, emoji);
|
||||||
}
|
}
|
||||||
return emojis;
|
return emojis;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user