From 80d52f525e2b407c67d6231f26fb80af197f40ee Mon Sep 17 00:00:00 2001 From: ShuriZma Date: Fri, 7 Jun 2024 09:37:55 +0200 Subject: [PATCH] fix missing endConnection call --- src/commands/fact.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/commands/fact.ts b/src/commands/fact.ts index 44a7da8..033c3f1 100644 --- a/src/commands/fact.ts +++ b/src/commands/fact.ts @@ -14,7 +14,8 @@ export default { bot.endConection(); let fact = results[0]; - await bot.getConnection().promise().execute('UPDATE facts SET counter = counter + 1 WHERE id = ?', [fact.id]) + await bot.getConnection().promise().execute('UPDATE facts SET counter = counter + 1 WHERE id = ?', [fact.id]); + bot.endConection(); console.log('Sent beaver fact with id: ' + fact.id); return await interaction.reply({