mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 18:13:29 +01:00
refactor(Role): move initialization of delete prop out of _patch (#6776)
This commit is contained in:
@@ -32,6 +32,12 @@ class Role extends Base {
|
||||
*/
|
||||
this.unicodeEmoji = null;
|
||||
|
||||
/**
|
||||
* Whether the role has been deleted
|
||||
* @type {boolean}
|
||||
*/
|
||||
this.deleted = false;
|
||||
|
||||
if (data) this._patch(data);
|
||||
}
|
||||
|
||||
@@ -97,12 +103,6 @@ class Role extends Base {
|
||||
this.mentionable = data.mentionable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether the role has been deleted
|
||||
* @type {boolean}
|
||||
*/
|
||||
this.deleted = false;
|
||||
|
||||
if ('icon' in data) this.icon = data.icon;
|
||||
|
||||
if ('unicode_emoji' in data) this.unicodeEmoji = data.unicode_emoji;
|
||||
|
||||
Reference in New Issue
Block a user