blob: ae69111b727c08d1e80f0ab48ae5d6b52a0989b1 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
import "dotenv/config";
import Fosscord from "fosscord-gopnik";
import Bot from "./Bot.js"; // huh?
import { initDatabase } from "@fosscord/util";
const client = new Fosscord.Client({
intents: ["GUILD_MESSAGES"],
http: {
api: process.env.ENDPOINT_API,
cdn: process.env.ENDPOINT_CDN,
invite: process.env.ENDPOINT_INV,
},
});
const bot = new Bot(client);
client.on("ready", bot.onReady);
client.on("messageCreate", bot.onMessageCreate);
(async () => {
await initDatabase();
await client.login(process.env.TOKEN);
})();
|