mirror of
https://github.com/warengroup/eximiabots-radiox.git
synced 2025-07-02 05:43:37 +00:00
Merge branch 'master' into fix-33
This commit is contained in:
@ -35,7 +35,7 @@ module.exports = {
|
||||
radio = currentRadios.next();
|
||||
}
|
||||
|
||||
const rest = new REST({ version: '9' }).setToken(token);
|
||||
/*const rest = new REST({ version: '9' }).setToken(token);
|
||||
if(version.includes("-dev")){
|
||||
await rest.put(
|
||||
Routes.applicationCommands(client.user.id),
|
||||
@ -47,13 +47,13 @@ module.exports = {
|
||||
try {
|
||||
await rest.put(
|
||||
Routes.applicationGuildCommands(client.user.id, guild.id),
|
||||
{ body: [] },
|
||||
{ body: [] }
|
||||
);
|
||||
} catch (DiscordAPIError) {
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
setInterval(() => {
|
||||
if(radio.done){
|
||||
|
@ -1,11 +1,9 @@
|
||||
import Discord from "discord.js";
|
||||
|
||||
module.exports = {
|
||||
name: 'interactionCreate',
|
||||
async execute(client, interaction) {
|
||||
|
||||
const permissions = interaction.channel.permissionsFor(interaction.client.user);
|
||||
if (!permissions.has('EMBED_LINKS')) return interaction.send(client.messages.noPermsEmbed);
|
||||
if (!permissions.has('EMBED_LINKS')) return interaction.reply(client.messages.noPermsEmbed);
|
||||
|
||||
if(interaction.isCommand()){
|
||||
const commandName = interaction.commandName;
|
||||
@ -13,7 +11,7 @@ module.exports = {
|
||||
if (!command) return;
|
||||
|
||||
try {
|
||||
command.execute(interaction, client, Discord, command);
|
||||
command.execute(interaction, client);
|
||||
} catch (error) {
|
||||
interaction.reply({
|
||||
content: client.messages.runningCommandFailed,
|
||||
@ -27,7 +25,7 @@ module.exports = {
|
||||
if (!command) return;
|
||||
|
||||
try {
|
||||
command.execute(interaction, client, Discord, command);
|
||||
command.execute(interaction, client, command);
|
||||
} catch (error) {
|
||||
interaction.reply({
|
||||
content: client.messages.runningCommandFailed,
|
||||
|
@ -22,7 +22,7 @@ module.exports = {
|
||||
if (!args[0]) return;
|
||||
const commandName = args[0].toLowerCase();
|
||||
if (commandName === 'none') return;
|
||||
const command = client.commands.get(commandName) || client.commands.find(cmd => cmd.aliases && cmd.aliases.includes(commandName)) || client.commandAliases.get(commandName);
|
||||
const command = client.commands.get(commandName) || client.commands.find(cmd => cmd.aliases && cmd.aliases.includes(commandName));
|
||||
if (!command && message.content !== `${prefix}`) return;
|
||||
const permissions = message.channel.permissionsFor(message.client.user);
|
||||
if (!permissions.has('EMBED_LINKS')) return message.channel.send(client.messages.noPermsEmbed);
|
||||
|
Reference in New Issue
Block a user