Add database

This commit is contained in:
Myx
2024-05-12 19:44:36 +02:00
parent 99b1ee39df
commit 1d6f9c3fb2
23 changed files with 112 additions and 67 deletions

10
bot.ts
View File

@@ -17,14 +17,15 @@ import {
import { ChannelType, Collection, GuildBasedChannel, Snowflake, VoiceChannel, VoiceState } from 'discord.js';
import * as dotenv from 'dotenv';
import * as schedule from 'node-schedule';
import { loadAvoidList } from './helpers/load-avoid-list';
import { LoggerColors } from './helpers/logger-colors';
import { getRandomSoundFilePath } from './helpers/get-random-sound-file-path';
import { loadAvoidList } from './helpers/loadAvoidList';
import { LoggerColors } from './helpers/loggerColors';
import { getRandomSoundFilePath } from './helpers/getRandomSoundFilePath';
import { logger } from './helpers/logger';
import { SetupDiscordCLient } from './helpers/setup-discord-client';
import { SetupDiscordCLient } from './helpers/setupDiscordClient';
import { convertHoursToMinutes, dateToString } from './helpers/converters';
import { AvoidList } from './models/avoid-list';
import { runServer } from './client/router';
import { startDatabase } from './client/database';
dotenv.config();
@@ -40,6 +41,7 @@ discordClient.on('ready', async () => {
joinRandomChannel(voiceChannelRetries);
runServer();
startDatabase();
});
/**