Webpack build for branch master: 7779069e32

This commit is contained in:
Travis CI 2017-04-30 22:58:15 +00:00
parent 4d3370c082
commit f30814b825
2 changed files with 28 additions and 1 deletions

View file

@ -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

File diff suppressed because one or more lines are too long