From 94a51f561a7d8fe4810cf6725729f63bc86eb0ac Mon Sep 17 00:00:00 2001 From: Dominik K Date: Fri, 14 Oct 2022 22:11:04 +0200 Subject: [PATCH 1/4] Replace timeout with cron --- src/util/Models/guildModel.js | 1 + src/util/dailyMsgs.js | 176 +++++++++++++++++++++------------- src/util/dbHandler.js | 3 +- yarn.lock | 18 +++- 4 files changed, 130 insertions(+), 68 deletions(-) diff --git a/src/util/Models/guildModel.js b/src/util/Models/guildModel.js index 24ad1a03..7e313139 100644 --- a/src/util/Models/guildModel.js +++ b/src/util/Models/guildModel.js @@ -35,6 +35,7 @@ const guildProfile = new Schema( }, dailyDay: { type: Number, + default: 0, }, nsfw: { type: Boolean, diff --git a/src/util/dailyMsgs.js b/src/util/dailyMsgs.js index ca8e2b54..cb300ee5 100644 --- a/src/util/dailyMsgs.js +++ b/src/util/dailyMsgs.js @@ -1,72 +1,118 @@ -const { EmbedBuilder } = require('discord.js'); -const guildLang = require('./Models/guildModel'); +const { EmbedBuilder } = require("discord.js"); +const cron = require('node-cron'); +const guildLang = require("./Models/guildModel"); const mom = require("moment-timezone"); module.exports = async (client) => { - setInterval(async function () { - const guilds = await guildLang.find(); - guilds.map(async db => { - if (!db.dailyMsg) return; - if (!client.channels.cache.get(db.dailyChannel)) return - if (db.dailyDay && db.dailyDay !== new Date().getDay()) return; - if (mom.tz(db.dailyTimezone).format("HH") === "12") { - const { Useless_Powers, Useful_Powers, } = await require(`../data/power-${db.language}.json`); - const { WouldYou } = await require(`../languages/${db.language}.json`); - let power; - if (db.customTypes === "regular") { - let array = []; - array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); - array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); - power = array[Math.floor(Math.random() * array.length)] - array = []; - } else if (db.customTypes === "mixed") { - let array = []; - if (db.customMessages.filter(c => c.type !== "nsfw") != 0) { - array.push(db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg); - } else { - power = Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; - } - array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); - array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); - power = array[Math.floor(Math.random() * array.length)] - array = []; - } else if (db.customTypes === "custom") { - if (db.customMessages.filter(c => c.type !== "nsfw") == 0) return client.channels.cache - .get(db.dailyChannel) - .send({ ephemeral: true, content: "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages." }) - power = db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg; - } + console.log("Daily message loaded"); - const embed = new EmbedBuilder() - .setColor('#0598F6') - .setFooter({ - text: `${WouldYou.embed.footer}`, - iconURL: client.user.avatarURL(), - }) - .setTimestamp() - .addFields({ - name: WouldYou.embed.Usefulname, - value: `> ${power}`, - inline: false, - }); + var CronJob = require('cron').CronJob; + var job = new CronJob( + '1 * * * * *', + function() { + console.log("Daily message sent"); + dailyMsg(); + }, + null, + true, + `America/Los_Angeles` +); +job.start(); - if (db.dailyRole) { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }).catch(() => { }) - } else { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed] }).catch(() => { }) - } + async function dailyMsg() { + console.log("Daily message function ran"); + const guilds = await guildLang.find(); + guilds.map(async (db) => { + if (!db.dailyMsg) return; + if (!client.channels.cache.get(db.dailyChannel)) return; + if (db.dailyDay && db.dailyDay !== new Date().getDay()) return; + if (mom.tz(db.dailyTimezone).format("HH") === "12") { + const { Useless_Powers, Useful_Powers } = + await require(`../data/power-${db.language}.json`); + const { WouldYou } = await require(`../languages/${db.language}.json`); + let power; + if (db.customTypes === "regular") { + let array = []; + array.push( + Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)] + ); + array.push( + Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)] + ); + power = array[Math.floor(Math.random() * array.length)]; + array = []; + } else if (db.customTypes === "mixed") { + let array = []; + if (db.customMessages.filter((c) => c.type !== "nsfw") != 0) { + array.push( + db.customMessages.filter((c) => c.type !== "nsfw")[ + Math.floor( + Math.random() * + db.customMessages.filter((c) => c.type !== "nsfw").length + ) + ].msg + ); + } else { + power = + Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; + } + array.push( + Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)] + ); + array.push( + Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)] + ); + power = array[Math.floor(Math.random() * array.length)]; + array = []; + } else if (db.customTypes === "custom") { + if (db.customMessages.filter((c) => c.type !== "nsfw") == 0) + return client.channels.cache + .get(db.dailyChannel) + .send({ + ephemeral: true, + content: + "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages.", + }); + power = db.customMessages.filter((c) => c.type !== "nsfw")[ + Math.floor( + Math.random() * + db.customMessages.filter((c) => c.type !== "nsfw").length + ) + ].msg; + } - if (db.dailyDay === 6) { - db.dailyDay = 0; - return db.save() - } + const embed = new EmbedBuilder() + .setColor("#0598F6") + .setFooter({ + text: `${WouldYou.embed.footer}`, + iconURL: client.user.avatarURL(), + }) + .setTimestamp() + .addFields({ + name: WouldYou.embed.Usefulname, + value: `> ${power}`, + inline: false, + }); - db.dailyDay = new Date().getDay() + 1; - db.save() - } - }) - }, 4000) + if (db.dailyRole) { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }) + .catch((err) => { console.log(err) }); + } else { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed] }) + .catch((err) => { console.log(err) }); + } + + if (db.dailyDay === 6 ) { + db.dailyDay = 0; + return db.save(); + } + + db.dailyDay = new Date().getDay() + 1; + db.save(); + } + }); + }; }; diff --git a/src/util/dbHandler.js b/src/util/dbHandler.js index 3fd58f62..85927dbc 100644 --- a/src/util/dbHandler.js +++ b/src/util/dbHandler.js @@ -3,8 +3,9 @@ require('dotenv').config(); const { ChalkAdvanced } = require('chalk-advanced'); -connect(process.env.MONGO_URI || 'mongodb://localhost:27017/wouldyou', { +connect(process.env.MONGO_URI, { useNewUrlParser: true, + serverSelectionTimeoutMS: 1000 }).then(() => console.log( `${ChalkAdvanced.white('Database')} ${ChalkAdvanced.gray( '>', diff --git a/yarn.lock b/yarn.lock index b103382b..419fd836 100644 --- a/yarn.lock +++ b/yarn.lock @@ -251,7 +251,7 @@ asynckit@^0.4.0: resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== -axios@^0.27.2, axios@^0.27.3: +axios@^0.27.2: version "0.27.2" resolved "https://registry.yarnpkg.com/axios/-/axios-0.27.2.tgz#207658cc8621606e586c85db4b41a750e756d972" integrity sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ== @@ -259,6 +259,15 @@ axios@^0.27.2, axios@^0.27.3: follow-redirects "^1.14.9" form-data "^4.0.0" +axios@^0.27.3: + version "1.1.2" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.1.2.tgz#8b6f6c540abf44ab98d9904e8daf55351ca4a331" + integrity sha512-bznQyETwElsXl2RK7HLLwb5GPpOLlycxHCtrpDR/4RqqBzjARaOTo3jz4IgtntWUYee7Ne4S8UHd92VCuzPaWA== + dependencies: + follow-redirects "^1.15.0" + form-data "^4.0.0" + proxy-from-env "^1.1.0" + balanced-match@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" @@ -891,7 +900,7 @@ flatted@^3.1.0: resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.7.tgz#609f39207cb614b89d0765b477cb2d437fbf9787" integrity sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ== -follow-redirects@^1.14.9: +follow-redirects@^1.14.9, follow-redirects@^1.15.0: version "1.15.2" resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.2.tgz#b460864144ba63f2681096f274c4e57026da2c13" integrity sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA== @@ -1633,6 +1642,11 @@ proxy-addr@~2.0.7: forwarded "0.2.0" ipaddr.js "1.9.1" +proxy-from-env@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" + integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== + pstree.remy@^1.1.8: version "1.1.8" resolved "https://registry.yarnpkg.com/pstree.remy/-/pstree.remy-1.1.8.tgz#c242224f4a67c21f686839bbdb4ac282b8373d3a" From 8e37a52a57aaec0dc0bcd7bb1b332f9ed7a7885a Mon Sep 17 00:00:00 2001 From: Dominik K Date: Fri, 14 Oct 2022 22:47:20 +0200 Subject: [PATCH 2/4] synced with skys code --- src/util/dailyMsgs.js | 154 ++++++++++++++++-------------------------- 1 file changed, 60 insertions(+), 94 deletions(-) diff --git a/src/util/dailyMsgs.js b/src/util/dailyMsgs.js index cb300ee5..cbf2f008 100644 --- a/src/util/dailyMsgs.js +++ b/src/util/dailyMsgs.js @@ -1,5 +1,5 @@ const { EmbedBuilder } = require("discord.js"); -const cron = require('node-cron'); + const guildLang = require("./Models/guildModel"); const mom = require("moment-timezone"); module.exports = async (client) => { @@ -7,112 +7,78 @@ module.exports = async (client) => { var CronJob = require('cron').CronJob; var job = new CronJob( - '1 * * * * *', + '* * * * * *', function() { console.log("Daily message sent"); dailyMsg(); }, null, true, - `America/Los_Angeles` + `Europe/Berlin` ); job.start(); async function dailyMsg() { - console.log("Daily message function ran"); - const guilds = await guildLang.find(); - guilds.map(async (db) => { + const guilds = await guildLang.find(); + guilds.map(async db => { if (!db.dailyMsg) return; - if (!client.channels.cache.get(db.dailyChannel)) return; - if (db.dailyDay && db.dailyDay !== new Date().getDay()) return; - if (mom.tz(db.dailyTimezone).format("HH") === "12") { - const { Useless_Powers, Useful_Powers } = - await require(`../data/power-${db.language}.json`); - const { WouldYou } = await require(`../languages/${db.language}.json`); - let power; - if (db.customTypes === "regular") { - let array = []; - array.push( - Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)] - ); - array.push( - Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)] - ); - power = array[Math.floor(Math.random() * array.length)]; - array = []; - } else if (db.customTypes === "mixed") { - let array = []; - if (db.customMessages.filter((c) => c.type !== "nsfw") != 0) { - array.push( - db.customMessages.filter((c) => c.type !== "nsfw")[ - Math.floor( - Math.random() * - db.customMessages.filter((c) => c.type !== "nsfw").length - ) - ].msg - ); - } else { - power = - Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; - } - array.push( - Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)] - ); - array.push( - Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)] - ); - power = array[Math.floor(Math.random() * array.length)]; - array = []; - } else if (db.customTypes === "custom") { - if (db.customMessages.filter((c) => c.type !== "nsfw") == 0) - return client.channels.cache - .get(db.dailyChannel) - .send({ - ephemeral: true, - content: - "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages.", - }); - power = db.customMessages.filter((c) => c.type !== "nsfw")[ - Math.floor( - Math.random() * - db.customMessages.filter((c) => c.type !== "nsfw").length - ) - ].msg; - } - - const embed = new EmbedBuilder() - .setColor("#0598F6") - .setFooter({ - text: `${WouldYou.embed.footer}`, - iconURL: client.user.avatarURL(), - }) - .setTimestamp() - .addFields({ - name: WouldYou.embed.Usefulname, - value: `> ${power}`, - inline: false, - }); + if (!isNaN(db.dailyDay)) { if (db.dailyDay === new Date().getDay()) return; } + if (mom.tz(db.dailyTimezone).format("HH:mm") === "16:25") { + db.dailyDay = new Date().getDay(); + db.save(); - if (db.dailyRole) { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }) - .catch((err) => { console.log(err) }); - } else { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed] }) - .catch((err) => { console.log(err) }); - } + const { Useless_Powers, Useful_Powers, } = await require(`../data/power-${db.language}.json`); + const { WouldYou } = await require(`../languages/${db.language}.json`); + let power; + if (db.customTypes === "regular") { + let array = []; + array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); + array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); + power = array[Math.floor(Math.random() * array.length)] + array = []; + } else if (db.customTypes === "mixed") { + let array = []; + if (db.customMessages.filter(c => c.type !== "nsfw") != 0) { + array.push(db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg); + } else { + power = Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; + } + array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); + array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); + power = array[Math.floor(Math.random() * array.length)] + array = []; + } else if (db.customTypes === "custom") { + if (db.customMessages.filter(c => c.type !== "nsfw") == 0) return client.channels.cache + .get(db.dailyChannel) + .send({ ephemeral: true, content: "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages." }) + power = db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg; + } - if (db.dailyDay === 6 ) { - db.dailyDay = 0; - return db.save(); - } + const embed = new EmbedBuilder() + .setColor('#0598F6') + .setFooter({ + text: `${WouldYou.embed.footer}`, + iconURL: client.user.avatarURL(), + }) + .setTimestamp() + .addFields({ + name: WouldYou.embed.Usefulname, + value: `> ${power}`, + inline: false, + }); - db.dailyDay = new Date().getDay() + 1; - db.save(); + if (db.dailyRole) { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }) + .catch(() => { }) + } else { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed] }) + .catch(() => { }) + } } - }); - }; + }) +} }; From 4f8da85539bef586bdb110a6f7c187710f0b150e Mon Sep 17 00:00:00 2001 From: Dominik K Date: Fri, 14 Oct 2022 23:00:16 +0200 Subject: [PATCH 3/4] remove cron :D --- src/util/dailyMsgs.js | 142 +++++++++++++++++++----------------------- 1 file changed, 63 insertions(+), 79 deletions(-) diff --git a/src/util/dailyMsgs.js b/src/util/dailyMsgs.js index cbf2f008..366dd002 100644 --- a/src/util/dailyMsgs.js +++ b/src/util/dailyMsgs.js @@ -1,84 +1,68 @@ -const { EmbedBuilder } = require("discord.js"); - -const guildLang = require("./Models/guildModel"); +const { EmbedBuilder } = require('discord.js'); +const guildLang = require('./Models/guildModel'); const mom = require("moment-timezone"); module.exports = async (client) => { - console.log("Daily message loaded"); - - var CronJob = require('cron').CronJob; - var job = new CronJob( - '* * * * * *', - function() { - console.log("Daily message sent"); - dailyMsg(); - }, - null, - true, - `Europe/Berlin` -); -job.start(); - - async function dailyMsg() { - const guilds = await guildLang.find(); - guilds.map(async db => { - if (!db.dailyMsg) return; - if (!isNaN(db.dailyDay)) { if (db.dailyDay === new Date().getDay()) return; } - if (mom.tz(db.dailyTimezone).format("HH:mm") === "16:25") { - db.dailyDay = new Date().getDay(); - db.save(); + setInterval(async function () { + const guilds = await guildLang.find(); + guilds.map(async db => { + if (!db.dailyMsg) return; + if (!isNaN(db.dailyDay)) { if (db.dailyDay === new Date().getDay()) return; } + if (mom.tz(db.dailyTimezone).format("HH:mm") === "16:25") { + db.dailyDay = new Date().getDay(); + db.save(); - const { Useless_Powers, Useful_Powers, } = await require(`../data/power-${db.language}.json`); - const { WouldYou } = await require(`../languages/${db.language}.json`); - let power; - if (db.customTypes === "regular") { - let array = []; - array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); - array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); - power = array[Math.floor(Math.random() * array.length)] - array = []; - } else if (db.customTypes === "mixed") { - let array = []; - if (db.customMessages.filter(c => c.type !== "nsfw") != 0) { - array.push(db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg); - } else { - power = Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; - } - array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); - array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); - power = array[Math.floor(Math.random() * array.length)] - array = []; - } else if (db.customTypes === "custom") { - if (db.customMessages.filter(c => c.type !== "nsfw") == 0) return client.channels.cache - .get(db.dailyChannel) - .send({ ephemeral: true, content: "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages." }) - power = db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg; - } + const { Useless_Powers, Useful_Powers, } = await require(`../data/power-${db.language}.json`); + const { WouldYou } = await require(`../languages/${db.language}.json`); + let power; + if (db.customTypes === "regular") { + let array = []; + array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); + array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); + power = array[Math.floor(Math.random() * array.length)] + array = []; + } else if (db.customTypes === "mixed") { + let array = []; + if (db.customMessages.filter(c => c.type !== "nsfw") != 0) { + array.push(db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg); + } else { + power = Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]; + } + array.push(Useful_Powers[Math.floor(Math.random() * Useful_Powers.length)]); + array.push(Useless_Powers[Math.floor(Math.random() * Useless_Powers.length)]); + power = array[Math.floor(Math.random() * array.length)] + array = []; + } else if (db.customTypes === "custom") { + if (db.customMessages.filter(c => c.type !== "nsfw") == 0) return client.channels.cache + .get(db.dailyChannel) + .send({ ephemeral: true, content: "There's currently no custom Would You messages to be displayed for daily messages! Either make new ones or turn off daily messages." }) + power = db.customMessages.filter(c => c.type !== "nsfw")[Math.floor(Math.random() * db.customMessages.filter(c => c.type !== "nsfw").length)].msg; + } - const embed = new EmbedBuilder() - .setColor('#0598F6') - .setFooter({ - text: `${WouldYou.embed.footer}`, - iconURL: client.user.avatarURL(), - }) - .setTimestamp() - .addFields({ - name: WouldYou.embed.Usefulname, - value: `> ${power}`, - inline: false, - }); + const embed = new EmbedBuilder() + .setColor('#0598F6') + .setFooter({ + text: `${WouldYou.embed.footer}`, + iconURL: client.user.avatarURL(), + }) + .setTimestamp() + .addFields({ + name: WouldYou.embed.Usefulname, + value: `> ${power}`, + inline: false, + }); - if (db.dailyRole) { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }) - .catch(() => { }) - } else { - client.channels.cache - .get(db.dailyChannel) - .send({ embeds: [embed] }) - .catch(() => { }) - } - } - }) -} -}; + if (db.dailyRole) { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed], content: `<@&${db.dailyRole}>` }) + .catch(() => { }) + } else { + client.channels.cache + .get(db.dailyChannel) + .send({ embeds: [embed] }) + .catch(() => { }) + } + } + }) + }, 30000) +}; \ No newline at end of file From 08292cfbbe5592c4e79e747a8998439584718653 Mon Sep 17 00:00:00 2001 From: Dominik K Date: Fri, 14 Oct 2022 23:01:48 +0200 Subject: [PATCH 4/4] Update dailyMsgs.js Co-Authored-By: ForGetFulSkyBro <47897305+forgetfulskybro@users.noreply.github.com> --- src/util/dailyMsgs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/dailyMsgs.js b/src/util/dailyMsgs.js index 366dd002..99d65b15 100644 --- a/src/util/dailyMsgs.js +++ b/src/util/dailyMsgs.js @@ -64,5 +64,5 @@ module.exports = async (client) => { } } }) - }, 30000) + }, 4000) }; \ No newline at end of file