From 1a3553cf866d69029a258508b3eda0e98d07d793 Mon Sep 17 00:00:00 2001 From: Abheek Dhawan Date: Sat, 19 Mar 2022 22:30:48 -0500 Subject: [PATCH] Use new logger for events --- events/interactionCreate.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/events/interactionCreate.js b/events/interactionCreate.js index e364cf2..7751d79 100644 --- a/events/interactionCreate.js +++ b/events/interactionCreate.js @@ -1,3 +1,5 @@ +const { log } = require('../helpers/log'); + module.exports = { name: 'interactionCreate', once: false, @@ -13,7 +15,7 @@ module.exports = { await command.execute(interaction); } catch (error) { - console.error(error); + log({ logger: 'interaction', content: `Interaction ${interaction.name} failed!`, level: 'error' }); await interaction.reply({ content: 'There was an error while executing this command!', ephemeral: true }); } },