3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-18 07:35:02 +00:00

Fix unknown users in logs in several places

This commit is contained in:
Dragory 2019-04-30 06:20:55 +03:00
parent 3e95e5920a
commit 2500b1db48
3 changed files with 12 additions and 12 deletions

View file

@ -102,11 +102,11 @@ export class CensorPlugin extends ZeppelinPlugin<ICensorPluginConfig> {
return;
}
const member = this.guild.members.get(savedMessage.user_id);
const user = await this.resolveUser(savedMessage.user_id);
const channel = this.guild.channels.get(savedMessage.channel_id);
this.serverLogs.log(LogType.CENSOR, {
member: stripObjectToScalars(member, ["user"]),
user: stripObjectToScalars(user),
channel: stripObjectToScalars(channel),
reason,
messageText: disableCodeBlocks(deactivateMentions(savedMessage.data.content)),