diff options
| author | Andrew Lee <alee14498@protonmail.com> | 2022-03-28 14:25:23 -0400 |
|---|---|---|
| committer | Andrew Lee <alee14498@protonmail.com> | 2022-03-28 14:25:23 -0400 |
| commit | 884e1acf7d3982e66f28dc2cd68e74325f704c6c (patch) | |
| tree | 8c3e97a7a84b4bf72dc25618376216341fcec6fd /deploy-command.js | |
| parent | 5ae481c84ea8edfd9e5589b331f32f453e6e5431 (diff) | |
| download | DLAP-884e1acf7d3982e66f28dc2cd68e74325f704c6c.tar.gz DLAP-884e1acf7d3982e66f28dc2cd68e74325f704c6c.tar.bz2 DLAP-884e1acf7d3982e66f28dc2cd68e74325f704c6c.zip | |
Added more buttons to control command
Diffstat (limited to 'deploy-command.js')
| -rw-r--r-- | deploy-command.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/deploy-command.js b/deploy-command.js index e11458a..c85637f 100644 --- a/deploy-command.js +++ b/deploy-command.js @@ -1,13 +1,13 @@ -const fs = require('node:fs'); -const { REST } = require('@discordjs/rest'); -const { Routes } = require('discord-api-types/v9'); -const config = require('./config.json'); +import fs from 'node:fs' +import { REST } from '@discordjs/rest' +import { Routes } from 'discord-api-types/v9' +import config from './config.json' assert {type: 'json'} const commands = []; const commandFiles = fs.readdirSync('./commands').filter(file => file.endsWith('.js')); for (const file of commandFiles) { - const command = require(`./commands/${file}`); + const { default: command } = await import(`./commands/${file}`); commands.push(command.data.toJSON()); } |
