From 654e2a23a6d6277a743a876675af85f757edba76 Mon Sep 17 00:00:00 2001 From: ry Date: Sun, 16 Feb 2020 22:37:27 +0100 Subject: [PATCH] remove error catch thing --- DiscordEvents/message.js | 55 ++++++++++++++++++++-------------------- 1 file changed, 28 insertions(+), 27 deletions(-) diff --git a/DiscordEvents/message.js b/DiscordEvents/message.js index c1bf651..2911534 100755 --- a/DiscordEvents/message.js +++ b/DiscordEvents/message.js @@ -109,34 +109,35 @@ module.exports = { cmd.command(ctx).then(async () => { if (!ctx.config.type.beta) ctx.client.channels.find(c => c.id === vars.logs.usage).send(`${ctx.utils.format.bold(ctx.author.tag)} (${ctx.utils.format.code(ctx.author.id)}) used ${ctx.utils.format.code(cmd.name)} in ${ctx.utils.format.bold(ctx.guild.name)} (${ctx.utils.format.code(ctx.guild.id)}) `).catch(e => console.log(e)) await ctx.db.backend.add(`usage.${cmd.name}`, 1) - }).catch((err) => { - if (!cmd.name === 'e926' || !cmd.name === 'e621') { - trello - .addCard( - cmd.name + ' | ' + err.message, - `Full Error: - ${err} + }) + /* .catch((err) => { + if (!cmd.name === 'e926' || !cmd.name === 'e621') { + trello + .addCard( + cmd.name + ' | ' + err.message, + `Full Error: + ${err} - Content: ${ctx.msg.content} - - Author: ${msg.author.tag} (${msg.author.id}) - Server: ${msg.guild.name} (${msg.guild.id})`, - config.trello.boards.errors - ) - .then((r) => { - trello - .addLabelToCard(r.id, config.trello.labels.errors) - .catch((error) => console.log(error)); - }) - .catch((err) => console.log(err)); - } - //console.warn(err.message); - let ErrorEmb = new MessageEmbed(); - ErrorEmb.setTitle(`${cmd.name} encountered an Error`) - .setDescription(`\`${err.message}\`\n\n\`${err}\``) - .setColor('RED'); - return ctx.send(ErrorEmb); - }); + Content: ${ctx.msg.content} + + Author: ${msg.author.tag} (${msg.author.id}) + Server: ${msg.guild.name} (${msg.guild.id})`, + config.trello.boards.errors + ) + .then((r) => { + trello + .addLabelToCard(r.id, config.trello.labels.errors) + .catch((error) => console.log(error)); + }) + .catch((err) => console.log(err)); + } + //console.warn(err.message); + let ErrorEmb = new MessageEmbed(); + ErrorEmb.setTitle(`${cmd.name} encountered an Error`) + .setDescription(`\`${err.message}\`\n\n\`${err}\``) + .setColor('RED'); + return ctx.send(ErrorEmb); + }); */ } } }; \ No newline at end of file