From 61015c0e3a20e9285264bf7c9ba5cc2b74fb8e10 Mon Sep 17 00:00:00 2001 From: "Navy.gif" Date: Tue, 10 May 2022 00:06:01 +0300 Subject: [PATCH] more fixes --- src/structure/components/observers/Automoderation.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/structure/components/observers/Automoderation.js b/src/structure/components/observers/Automoderation.js index b881db8..d20a9d1 100644 --- a/src/structure/components/observers/Automoderation.js +++ b/src/structure/components/observers/Automoderation.js @@ -398,7 +398,8 @@ module.exports = class AutoModeration extends Observer { this.logger.error('Error in message flag:\n' + err.stack); }); - await this.client.storageManager.mongodb.wordwatcher.insertOne({ + // Only insert if actions are defined + if(actionRow) await this.client.storageManager.mongodb.wordwatcher.insertOne({ message: sent.id, target: msg.id, channel: msg.channel.id,