refactor: Move me and add fetchMe() (fix)

This commit is contained in:
March 7th
2023-01-11 18:03:13 +07:00
parent bacb672045
commit 83f4181ec7
3 changed files with 3 additions and 3 deletions

View File

@@ -55,7 +55,7 @@ class GuildEmoji extends BaseGuildEmoji {
* @readonly
*/
get deletable() {
if (!this.guild.me) throw new Error('GUILD_UNCACHED_ME');
if (!this.guild.members.me) throw new Error('GUILD_UNCACHED_ME');
return !this.managed && this.guild.members.me.permissions.has(Permissions.FLAGS.MANAGE_EMOJIS_AND_STICKERS);
}