forked from Galactic/modmail
bugfix
This commit is contained in:
parent
78fe35ef39
commit
771290e76c
@ -247,7 +247,7 @@ class ChannelHandler
|
||||
if (!user)
|
||||
return reject(new Error('Failed to find user'));
|
||||
const mem = await this.modmail.getMember(user.id).catch(this.logger.error.bind(this.logger));
|
||||
const mbr = mem?.struct as GuildMember;
|
||||
const mbr = mem?.struct;
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-shadow
|
||||
const embed: APIEmbed = {
|
||||
@ -262,7 +262,7 @@ class ChannelHandler
|
||||
},
|
||||
// eslint-disable-next-line no-nested-ternary
|
||||
description: entry.content && entry.content.length ? entry.content.length > 2000 ? `${entry.content.substring(0, 2000)}...\n\n**Content cut off**` : entry.content : '**__MISSING CONTENT__**',
|
||||
color: mbr.roles.highest.color || 0,
|
||||
color: mbr?.roles.highest.color || 0,
|
||||
fields: [],
|
||||
timestamp: new Date(entry.timestamp).toISOString()
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user