mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-03-15 05:41:51 +00:00
Fix possible error in error handling
This commit is contained in:
parent
69a1df260e
commit
c573ec5d5f
1 changed files with 1 additions and 1 deletions
|
@ -52,7 +52,7 @@ if (process.env.NODE_ENV === "production") {
|
|||
// Log it in the console as a warning and post a warning to the guild's log.
|
||||
|
||||
// tslint:disable:no-console
|
||||
console.warn(`${err.guild.name}: [${err.code}] ${err.message}`);
|
||||
console.warn(`${err.guild?.name || "Global"}: [${err.code}] ${err.message}`);
|
||||
|
||||
const logs = new GuildLogs(err.guild.id);
|
||||
logs.log(LogType.BOT_ALERT, { body: `\`[${err.code}]\` ${err.message}` });
|
||||
|
|
Loading…
Add table
Reference in a new issue