2023-10-13 15:04:11 +02:00
|
|
|
import { SlashCommandBuilder } from "discord.js";
|
|
|
|
import { deploy_commands } from "../../functions.mjs";
|
|
|
|
import config from "../../config.json" assert { type: "json" };
|
2023-09-13 21:12:45 +02:00
|
|
|
const { devId } = config;
|
2022-11-09 14:44:05 +01:00
|
|
|
|
2023-09-13 21:12:45 +02:00
|
|
|
export default {
|
2022-12-16 08:26:32 +01:00
|
|
|
data: new SlashCommandBuilder()
|
2023-10-13 15:04:11 +02:00
|
|
|
.setName("reload")
|
2022-11-09 14:44:05 +01:00
|
|
|
.setDefaultMemberPermissions(0x8)
|
2023-10-13 15:04:11 +02:00
|
|
|
.setDescription("Recharge les commandes du bot (dev only)."),
|
2022-12-16 08:26:32 +01:00
|
|
|
async execute(interaction, client) {
|
2023-10-13 15:04:11 +02:00
|
|
|
if (!interaction.user.id == devId)
|
|
|
|
return void interaction.reply({ content: "Permission denied" });
|
2022-11-09 14:44:05 +01:00
|
|
|
deploy_commands(client, false);
|
2023-10-13 15:04:11 +02:00
|
|
|
},
|
2022-12-16 08:26:32 +01:00
|
|
|
};
|