mirror of
https://github.com/warengroup/eximiabots-radiox.git
synced 2024-11-09 23:00:18 +00:00
Removed permissions property from commands
This commit is contained in:
parent
33e4a416a9
commit
1371a83e90
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'bug',
|
||||
description: 'Report a bug',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
async execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'help',
|
||||
description: 'Get help using bot',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'invite',
|
||||
description: 'Invite Bot',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'list',
|
||||
description: 'List radio stations',
|
||||
permission: 'none',
|
||||
category: 'radio',
|
||||
execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -4,7 +4,6 @@ import fetch from "node-fetch";
|
||||
module.exports = {
|
||||
name: 'maintenance',
|
||||
description: 'Bot Maintenance',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
options: [
|
||||
{ type: "NUMBER", name: "action", description: "Select action", required: false}
|
||||
|
@ -1,7 +1,6 @@
|
||||
module.exports = {
|
||||
name: 'next',
|
||||
description: 'Next Station',
|
||||
permission: 'none',
|
||||
category: 'radio',
|
||||
async execute(interaction, client, command) {
|
||||
if (client.funcs.check(client, interaction, command)) {
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'nowplaying',
|
||||
description: 'Current Radio Station',
|
||||
permission: 'none',
|
||||
category: 'radio',
|
||||
async execute(interaction, client, command) {
|
||||
if (client.funcs.check(client, interaction, command)) {
|
||||
|
@ -11,7 +11,6 @@ module.exports = {
|
||||
options: [
|
||||
{ type: "STRING", name: "query", description: "Select station", required: false}
|
||||
],
|
||||
permission: "none",
|
||||
category: "radio",
|
||||
async execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -1,7 +1,6 @@
|
||||
module.exports = {
|
||||
name: 'prev',
|
||||
description: 'Previous Station',
|
||||
permission: 'none',
|
||||
category: 'radio',
|
||||
async execute(interaction, client, command) {
|
||||
if (client.funcs.check(client, interaction, command)) {
|
||||
|
@ -4,7 +4,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'statistics',
|
||||
description: 'Show statistics',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'status',
|
||||
description: 'Bot Status',
|
||||
permission: 'none',
|
||||
category: 'info',
|
||||
async execute(interaction, client) {
|
||||
let message = {};
|
||||
|
@ -3,7 +3,6 @@ import Discord from "discord.js";
|
||||
module.exports = {
|
||||
name: 'stop',
|
||||
description: 'Stop radio',
|
||||
permission: 'none',
|
||||
category: 'radio',
|
||||
async execute(interaction, client, command) {
|
||||
const radio = client.radio.get(interaction.guild.id);
|
||||
|
@ -24,14 +24,6 @@ module.exports = function (client, interaction, command) {
|
||||
});
|
||||
return false;
|
||||
}
|
||||
if(!command.permission == 'none'){
|
||||
if (!permissions.has(command.permission)) {
|
||||
message.noPerms = client.messages.noPerms.replace("%command.permission%", command.permission);
|
||||
interaction.reply({
|
||||
content: client.messageEmojis["error"] + message.noPerms,
|
||||
ephemeral: true
|
||||
});
|
||||
return false;
|
||||
} else return true;
|
||||
} else return true;
|
||||
|
||||
return true;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user