1
0
mirror of https://github.com/toast-ts/Daggerbot-TS.git synced 2024-11-16 20:00:59 -05:00

Yarn.lock maintenance

This commit is contained in:
toast-ts 2024-04-26 20:44:00 +10:00
parent e9af56c19c
commit 3e161f948c
4 changed files with 10 additions and 8 deletions

View File

@ -31,7 +31,7 @@
"@octokit/rest": "20.1.0",
"@sequelize/core": "7.0.0-alpha.40",
"@sequelize/postgres": "7.0.0-alpha.40",
"@toast/tokenservice-client": "1.2.6",
"@toast/tokenservice-client": "1.2.7",
"ansi-colors": "4.1.3",
"dayjs": "1.11.10",
"discord.js": "14.14.1",

View File

@ -6,6 +6,7 @@ import UsernameHelper from '../helpers/UsernameHelper.js';
import Formatters from '../helpers/Formatters.js';
import GitHub from '../helpers/GitHub.js';
import TClient from '../client.js';
import cron from 'node-cron';
import util from 'node:util';
import fs from 'node:fs';
export default class Developer {
@ -14,6 +15,7 @@ export default class Developer {
({
eval: async()=>{
fs;
cron;
DatabaseServer;
const code = interaction.options.getString('code') as string;

View File

@ -27,13 +27,13 @@ if ((typeof process.argv[4] === 'string' && process.argv[4] === 'true') ?? null)
// Interval timers for modules
setInterval(async()=>await MPModule(client), refreshTimerSecs);
cron.schedule('0-5 * * * *', ()=>YTModule(client)); // Every minute from 0 through 5
cron.schedule('5-25 * * * *', async()=>{// Every minute from 5 through 25
cron.schedule('5-12 * * * *', async()=>{// Every minute from 5 through 12
const forum = client.guilds.cache.get(client.config.dcServer.id).channels.cache.get(client.config.dcServer.channels.help_forum) as Discord.ForumChannel;
await forum.threads.fetch();
for await (const thread of forum.threads.cache.values()) {
await thread.messages.fetch();
if (!thread.archived && thread.lastMessage.createdTimestamp <= Date.now() - 1555200000) {// check if thread is inactive for over 18 days
if ((!thread.locked || !thread.archived) && thread.lastMessage.createdTimestamp <= Date.now() - 1555200000) {// check if thread is inactive for over 18 days
await thread.delete();
Logger.console('log', 'ThreadTimer', `"#${thread.name}" has been deleted due to inactivity for 18 days`);
}

View File

@ -524,12 +524,12 @@ __metadata:
languageName: node
linkType: hard
"@toast/tokenservice-client@npm:1.2.6":
version: 1.2.6
resolution: "@toast/tokenservice-client@npm:1.2.6::__archiveUrl=https%3A%2F%2Fgit.toast-server.net%2Fapi%2Fpackages%2Ftoast%2Fnpm%2F%2540toast%252Ftokenservice-client%2F-%2F1.2.6%2Ftokenservice-client-1.2.6.tgz"
"@toast/tokenservice-client@npm:1.2.7":
version: 1.2.7
resolution: "@toast/tokenservice-client@npm:1.2.7::__archiveUrl=https%3A%2F%2Fgit.toast-server.net%2Fapi%2Fpackages%2Ftoast%2Fnpm%2F%2540toast%252Ftokenservice-client%2F-%2F1.2.7%2Ftokenservice-client-1.2.7.tgz"
dependencies:
undici: "npm:6.14.1"
checksum: 10/eabaacd8982d936e2d0b50ddc7bb5d19859c5fe345b86cb130e032f3d5e159b0d7760f7fea034b9a00dc202de0494e57bab228738a7240a13b501d207509db00
checksum: 10/e46cb44500acf96366aed1deeea76a1c66ff7184ec32b8b2f9b92f417f67f3542f4c1a478d036ce09fb7fb33286361869f60c44c19dca55d21c2e11239de3d5c
languageName: node
linkType: hard
@ -702,7 +702,7 @@ __metadata:
"@octokit/rest": "npm:20.1.0"
"@sequelize/core": "npm:7.0.0-alpha.40"
"@sequelize/postgres": "npm:7.0.0-alpha.40"
"@toast/tokenservice-client": "npm:1.2.6"
"@toast/tokenservice-client": "npm:1.2.7"
"@types/ms": "npm:0.7.34"
"@types/node": "npm:20.12.7"
"@types/node-cron": "npm:3.0.11"