From c3cce1a6d47867051cf1a2a0efea4b81beaf2368 Mon Sep 17 00:00:00 2001 From: WubzyGD Date: Fri, 21 May 2021 02:53:06 -0600 Subject: [PATCH] forgot these files --- events/messageDelete.js | 2 +- events/ready.js | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/events/messageDelete.js b/events/messageDelete.js index ea89835..b9e8b6a 100644 --- a/events/messageDelete.js +++ b/events/messageDelete.js @@ -1,7 +1,7 @@ const Discord = require('discord.js'); module.exports = async (client, message) => { - if (message.channel.type != "text") {return;}; + if (message.channel.type !== "text") {return;} //if (!Object.keys(snipe.delete).includes(message.guild.id)) {snipe.delete[message.guild.id] = {};}; //snipe.delete[message.guild.id][message.channel.id] = message; diff --git a/events/ready.js b/events/ready.js index fa4bd72..2b9917f 100644 --- a/events/ready.js +++ b/events/ready.js @@ -62,17 +62,17 @@ module.exports = async client => { if (tguild && tguild.prefix && tguild.prefix.length) {client.guildconfig.prefixes.set(tg.id, tguild.prefix);} let tl = await LogData.findOne({gid: tg.id}); if (tl) { - let keys = Object.keys(tl); - let k; for (k of keys) {if (typeof tl[k] === "string" && tl[k].length) { + let keys = Object.keys(tl.logs); + let k; for (k of keys) {if (typeof tl.logs[k] === "string" && tl.logs[k].length) { if (!client.guildconfig.logs.has(tg.id)) {client.guildconfig.logs.set(tg.id, new Map());} - client.guildconfig.logs.get(tg.id).set(k, tl[k]); + client.guildconfig.logs.get(tg.id).set(k, tl.logs[k]); }} } }}; setPL(); siftStatuses(); - setInterval(() => {setPL(); siftStatuses(client, null);}, 120000); + setInterval(() => {siftStatuses(client, null);}, 120000); await require('../util/cache')(client);