what the helk!?

This commit is contained in:
Ashley Graves 2024-10-15 15:09:04 +02:00
parent 7c210ee7a6
commit bfb14f4b15
14 changed files with 771 additions and 3 deletions

View file

@ -1,5 +1,6 @@
const { REST, Routes, Client, Collection, GatewayIntentBits, Events, Partials, InteractionType, ActivityType } = require("discord.js");
const { default: Groq } = require("groq-sdk");
const server = require("./server");
const { knex } = require("./db.js");
const path = require("node:path");
const fs = require("node:fs");
@ -73,11 +74,15 @@ client.on(Events.InteractionCreate, async interaction => {
client.once(Events.ClientReady, async () => {
console.log(`Ready! Logged in as ${client.user.displayName}`);
client.user.setActivity({
name: "kissing my sister",
type: ActivityType.Custom
});
server.setClient(client);
server.start();
if (!(await knex.schema.hasTable("blacklists")))
await knex.schema.createTable("blacklists", function (table) {
table.string("user").primary();
@ -96,6 +101,12 @@ client.once(Events.ClientReady, async () => {
table.string("data");
});
if (!(await knex.schema.hasTable("pastes")))
await knex.schema.createTable("pastes", function (table) {
table.string("id").primary();
table.string("data");
});
var user = client.user.toJSON();
for (const prompt of fs.readdirSync(promptsDir)) {