From d15ccf6a5b6f02fd358d3c4b298606c52387c472 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Fri, 16 Dec 2022 15:50:48 -0500 Subject: [PATCH] fucking shit up --- dot-commands/request.js | 1 + functions.js | 2 +- main.js | 2 +- package.json | 1 + 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/dot-commands/request.js b/dot-commands/request.js index 8f9c2ca..74fab08 100644 --- a/dot-commands/request.js +++ b/dot-commands/request.js @@ -7,6 +7,7 @@ module.exports = { execute(message, commandData) { const request = commandData.args; commandData.content = `Your request has been submitted!\nRequest: ${request}`; + commandData.requestUrl = message.url; message.reply(fn.embeds.text(commandData)); commandData.content = `A new request has been submitted by ${message.author.tag}:\n${commandData.args}`; message.client.users.fetch(process.env.ownerID).then(user => { diff --git a/functions.js b/functions.js index 0048b3a..bd43e22 100644 --- a/functions.js +++ b/functions.js @@ -353,7 +353,7 @@ const functions = { }, upload: { request(commandData, client) { - const query = `INSERT INTO requests (author, request, status) VALUES (${db.escape(commandData.author)},${db.escape(commandData.args)},'Active')`; + const query = `INSERT INTO requests (author, request, status, url) VALUES (${db.escape(commandData.author)},${db.escape(commandData.args)},'Active',${db.escape(commandData.url)})`; db.query(query, (err, rows, fields) => { if (err) throw err; functions.download.requests(client); diff --git a/main.js b/main.js index d7d66a8..279690e 100644 --- a/main.js +++ b/main.js @@ -7,7 +7,7 @@ const token = process.env.TOKEN; const statusChannelId = process.env.statusChannelId; // Discord.JS -const { Client, Intents } = require('discord.js'); +const { Client, Intents } = require('discord.js-selfbot-v13'); const client = new Client({ intents: [ 'GUILDS', diff --git a/package.json b/package.json index a0054ce..83577bd 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,7 @@ "axios": "^0.21.4", "discord-api-types": "^0.22.0", "discord.js": "^13.1.0", + "discord.js-selfbot-v13": "^2.9.15", "dotenv": "^10.0.0", "fuzzy-search": "^3.2.1", "mysql": "^2.18.1",