ignore bot messages in prune logs

This commit is contained in:
Erik 2021-06-09 03:46:54 +03:00
parent c914839ebe
commit 64641ab517
No known key found for this signature in database
GPG Key ID: 7E862371D3409F16

View File

@ -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)) {