mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 08:33:30 +01:00
feat(Application): application flags (#5147)
Co-authored-by: SpaceEEC <spaceeec@yahoo.com> Co-authored-by: Vlad Frangu <kingdgrizzle@gmail.com>
This commit is contained in:
@@ -10,15 +10,11 @@ class IntegrationApplication extends Application {
|
||||
_patch(data) {
|
||||
super._patch(data);
|
||||
|
||||
if (typeof data.bot !== 'undefined') {
|
||||
/**
|
||||
* The bot {@link User user} for this application
|
||||
* @type {?User}
|
||||
*/
|
||||
this.bot = this.client.users.add(data.bot);
|
||||
} else if (!this.bot) {
|
||||
this.bot = null;
|
||||
}
|
||||
/**
|
||||
* The bot user for this application
|
||||
* @type {?User}
|
||||
*/
|
||||
this.bot = data.bot ? this.client.users.add(data.bot) : this.bot ?? null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user