queue command init
This commit is contained in:
6
dist/index.js
vendored
6
dist/index.js
vendored
@@ -31,6 +31,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const discord_js_1 = require("discord.js");
|
||||
const fs = __importStar(require("fs"));
|
||||
const discord_1 = require("./discord");
|
||||
const queue_1 = require("./queue");
|
||||
const CLIENT = new discord_js_1.Client({ intents: [discord_js_1.Intents.FLAGS.GUILDS] });
|
||||
if (!fs.existsSync('./token')) {
|
||||
fs.writeFileSync('./token', '');
|
||||
@@ -45,8 +46,7 @@ CLIENT.on('ready', client => {
|
||||
CLIENT.on('interactionCreate', (interaction) => __awaiter(void 0, void 0, void 0, function* () {
|
||||
if (!interaction.isCommand())
|
||||
return;
|
||||
if (interaction.commandName === 'queue') {
|
||||
yield interaction.reply('Pong!');
|
||||
}
|
||||
if (interaction.commandName === 'queue')
|
||||
(0, queue_1.createQueue)(interaction);
|
||||
}));
|
||||
CLIENT.login(TOKEN);
|
||||
|
||||
Reference in New Issue
Block a user