mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 18:13:29 +01:00
refactor(Managers): rename add to _add (#6060)
This commit is contained in:
@@ -20,8 +20,8 @@ class GuildEmojiManager extends BaseGuildEmojiManager {
|
||||
this.guild = guild;
|
||||
}
|
||||
|
||||
add(data, cache) {
|
||||
return super.add(data, cache, { extras: [this.guild] });
|
||||
_add(data, cache) {
|
||||
return super._add(data, cache, { extras: [this.guild] });
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -94,12 +94,12 @@ class GuildEmojiManager extends BaseGuildEmojiManager {
|
||||
if (existing) return existing;
|
||||
}
|
||||
const emoji = await this.client.api.guilds(this.guild.id).emojis(id).get();
|
||||
return this.add(emoji, cache);
|
||||
return this._add(emoji, cache);
|
||||
}
|
||||
|
||||
const data = await this.client.api.guilds(this.guild.id).emojis.get();
|
||||
const emojis = new Collection();
|
||||
for (const emoji of data) emojis.set(emoji.id, this.add(emoji, cache));
|
||||
for (const emoji of data) emojis.set(emoji.id, this._add(emoji, cache));
|
||||
return emojis;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user