From 64641ab517c9dab6cd2ace599fa2a8ea9a3e0104 Mon Sep 17 00:00:00 2001 From: Navy Date: Wed, 9 Jun 2021 03:46:54 +0300 Subject: [PATCH] ignore bot messages in prune logs --- structure/client/components/observers/GuildLogging.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/structure/client/components/observers/GuildLogging.js b/structure/client/components/observers/GuildLogging.js index 921e0ca..c2abae9 100644 --- a/structure/client/components/observers/GuildLogging.js +++ b/structure/client/components/observers/GuildLogging.js @@ -241,6 +241,8 @@ class GuildLogger extends Observer { const cutOff = EmbedLimits.fieldValue;// - 3; const fields = []; + messages = messages.filter((msg) => !msg.author.bot); + //Compile messages into fields that can be compiled into embeds messageLoop: //Oldest messages first for (const message of messages.array().sort((a, b) => b.createdTimestamp - a.createdTimestamp)) {