mirror of
https://github.com/danbulant/discord.js
synced 2026-06-19 14:41:36 +00:00
Webpack build for branch master: 7779069e32
This commit is contained in:
parent
4d3370c082
commit
f30814b825
2 changed files with 28 additions and 1 deletions
|
|
@ -26474,6 +26474,33 @@ class GuildAuditLogsEntry {
|
|||
*/
|
||||
this.id = data.id;
|
||||
|
||||
/**
|
||||
* Any extra data from the entry
|
||||
* @type {?Object|Role|GuildMember}
|
||||
*/
|
||||
this.extra = null;
|
||||
if (data.options) {
|
||||
if (data.action_type === Actions.MEMBER_PRUNE) {
|
||||
this.extra = {
|
||||
removed: data.options.members_removed,
|
||||
days: data.options.delete_member_days,
|
||||
};
|
||||
} else {
|
||||
switch (data.options.type) {
|
||||
case 'member':
|
||||
this.extra = guild.members.get(this.options.id);
|
||||
if (!this.extra) this.extra = { id: this.options.id };
|
||||
break;
|
||||
case 'role':
|
||||
this.extra = guild.roles.get(this.options.id);
|
||||
if (!this.extra) this.extra = { id: this.options.id, name: this.options.role_name };
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ([Targets.USER, Targets.GUILD].includes(targetType)) {
|
||||
/**
|
||||
* The target of this entry
|
||||
|
|
|
|||
2
discord.master.min.js
vendored
2
discord.master.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue