From 7bccb1fe4d1aac9eae53995f4e8e84402a17d2cb Mon Sep 17 00:00:00 2001 From: JonnyBro Date: Thu, 13 Oct 2022 00:05:36 +0500 Subject: [PATCH] 4.1.11 - https://github.com/JonnyBro/JaBa-logs --- TO REWRITE/seek.js | 1 - base/BaseCommand.js | 4 ---- commands/Administration/automod.js | 3 ++- commands/Administration/autorole.js | 3 ++- commands/Administration/config.js | 3 ++- commands/Administration/goodbye.js | 3 ++- commands/Administration/set.js | 2 +- commands/Administration/setbirthdays.js | 3 ++- commands/Administration/setlang.js | 3 ++- commands/Administration/setmodlogs.js | 3 ++- commands/Administration/setnews.js | 3 ++- commands/Administration/setreports.js | 3 ++- commands/Administration/setsuggests.js | 3 ++- commands/Administration/stealemoji.js | 3 ++- commands/Administration/welcome.js | 3 ++- commands/Economy/achievements.js | 2 +- commands/Economy/bank.js | 2 +- commands/Economy/birthdate.js | 2 +- commands/Economy/divorce.js | 4 ++-- commands/Economy/importmee6.js | 4 ++-- commands/Economy/leaderboard.js | 2 +- commands/Economy/marry.js | 2 +- commands/Economy/money.js | 2 +- commands/Economy/number.js | 4 ++-- commands/Economy/pay.js | 2 +- commands/Economy/profile.js | 2 +- commands/Economy/rep.js | 2 +- commands/Economy/rob.js | 2 +- commands/Economy/setbio.js | 2 +- commands/Economy/slots.js | 2 +- commands/Economy/tictactoe.js | 2 +- commands/Economy/transactions.js | 2 +- commands/Economy/work.js | 4 ++-- commands/Fun/8ball.js | 2 +- commands/Fun/crab.js | 4 ++-- commands/Fun/lmgtfy.js | 2 +- commands/Fun/lovecalc.js | 2 +- commands/Fun/memes.js | 9 +++++---- commands/General/activity.js | 4 ++-- commands/General/afk.js | 2 +- commands/General/avatar.js | 2 +- commands/General/emoji.js | 2 +- commands/General/help.js | 2 +- commands/General/minecraft.js | 2 +- commands/General/ping.js | 4 ++-- commands/General/remindme.js | 2 +- commands/General/report.js | 2 +- commands/General/serverinfo.js | 4 ++-- commands/General/shorturl.js | 2 +- commands/General/staff.js | 4 ++-- commands/General/stats.js | 4 ++-- commands/General/suggest.js | 2 +- commands/General/userinfo.js | 2 +- commands/General/whois.js | 2 +- commands/Moderation/clear.js | 3 ++- commands/Moderation/clearwarns.js | 3 ++- commands/Moderation/giveaway.js | 3 ++- commands/Moderation/poll.js | 3 ++- commands/Moderation/unban.js | 3 ++- commands/Moderation/warn.js | 3 ++- commands/Moderation/warns.js | 3 ++- commands/Music/back.js | 4 ++-- commands/Music/clips.js | 4 ++-- commands/Music/loop.js | 2 +- commands/Music/nowplaying.js | 4 ++-- commands/Music/play.js | 2 +- commands/Music/queue.js | 4 ++-- commands/Music/shuffle.js | 4 ++-- commands/Music/skip.js | 4 ++-- commands/Music/skipto.js | 2 +- commands/Music/stop.js | 4 ++-- commands/NSFW/nsfw.js | 11 ++++++----- commands/Owner/announcement.js | 2 +- commands/Owner/debug.js | 2 +- commands/Owner/eval.js | 2 +- commands/Owner/reload.js | 2 +- commands/Owner/say.js | 2 +- commands/Owner/servers.js | 9 +++++---- dashboard/public/docs/updates.md | 7 +++++++ package.json | 2 +- 80 files changed, 133 insertions(+), 109 deletions(-) diff --git a/TO REWRITE/seek.js b/TO REWRITE/seek.js index 30289020..b48ac7e9 100644 --- a/TO REWRITE/seek.js +++ b/TO REWRITE/seek.js @@ -16,7 +16,6 @@ class Seek extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/base/BaseCommand.js b/base/BaseCommand.js index fc848c75..7a6a2a98 100644 --- a/base/BaseCommand.js +++ b/base/BaseCommand.js @@ -11,10 +11,6 @@ class BaseCommand { * @type {Array} */ this.aliases = options.aliases || []; - /** - * @type {Boolean} - */ - this.guildOnly = (options.guildOnly === true ? true : false) || false; /** * @type {Boolean} */ diff --git a/commands/Administration/automod.js b/commands/Administration/automod.js index f65afbf6..05aa9fce 100644 --- a/commands/Administration/automod.js +++ b/commands/Administration/automod.js @@ -11,6 +11,7 @@ class Automod extends BaseCommand { command: new SlashCommandBuilder() .setName("automod") .setDescription(client.translate("administration/automod:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Automod extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/autorole.js b/commands/Administration/autorole.js index ff79cefc..de3fa825 100644 --- a/commands/Administration/autorole.js +++ b/commands/Administration/autorole.js @@ -11,6 +11,7 @@ class Autorole extends BaseCommand { command: new SlashCommandBuilder() .setName("autorole") .setDescription(client.translate("administration/autorole:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -19,7 +20,7 @@ class Autorole extends BaseCommand { .setDescription(client.translate("common:ROLE"))), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/config.js b/commands/Administration/config.js index 59188106..ebccb11a 100644 --- a/commands/Administration/config.js +++ b/commands/Administration/config.js @@ -11,10 +11,11 @@ class Config extends BaseCommand { command: new SlashCommandBuilder() .setName("config") .setDescription(client.translate("administration/config:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/goodbye.js b/commands/Administration/goodbye.js index 563400cc..9e082a53 100644 --- a/commands/Administration/goodbye.js +++ b/commands/Administration/goodbye.js @@ -11,6 +11,7 @@ class Goodbye extends BaseCommand { command: new SlashCommandBuilder() .setName("goodbye") .setDescription(client.translate("administration/goodbye:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addSubcommand(subcommand => subcommand.setName("test") .setDescription(client.translate("administration/goodbye:TEST")) @@ -29,7 +30,7 @@ class Goodbye extends BaseCommand { ), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/set.js b/commands/Administration/set.js index b04e5a04..f73ef992 100644 --- a/commands/Administration/set.js +++ b/commands/Administration/set.js @@ -11,6 +11,7 @@ class Set extends BaseCommand { command: new SlashCommandBuilder() .setName("set") .setDescription(client.translate("administration/set:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addStringOption(option => option.setName("type") .setDescription(client.translate("owner/debug:TYPE")) @@ -29,7 +30,6 @@ class Set extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Administration/setbirthdays.js b/commands/Administration/setbirthdays.js index 9a6a1cfb..d7a8de29 100644 --- a/commands/Administration/setbirthdays.js +++ b/commands/Administration/setbirthdays.js @@ -11,6 +11,7 @@ class Setbirthdays extends BaseCommand { command: new SlashCommandBuilder() .setName("setbirthdays") .setDescription(client.translate("administration/setbirthdays:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Setbirthdays extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/setlang.js b/commands/Administration/setlang.js index 2533ff99..c2b39071 100644 --- a/commands/Administration/setlang.js +++ b/commands/Administration/setlang.js @@ -11,6 +11,7 @@ class Setlang extends BaseCommand { command: new SlashCommandBuilder() .setName("setlang") .setDescription(client.translate("administration/setlang:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addStringOption(option => option.setName("language") .setDescription(client.translate("common:LANGUAGE")) @@ -21,7 +22,7 @@ class Setlang extends BaseCommand { )), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/setmodlogs.js b/commands/Administration/setmodlogs.js index 0fcc618e..903a8db5 100644 --- a/commands/Administration/setmodlogs.js +++ b/commands/Administration/setmodlogs.js @@ -11,6 +11,7 @@ class Setmodlogs extends BaseCommand { command: new SlashCommandBuilder() .setName("setmodlogs") .setDescription(client.translate("administration/setmodlogs:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Setmodlogs extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/setnews.js b/commands/Administration/setnews.js index 920f4c8d..c13c6c55 100644 --- a/commands/Administration/setnews.js +++ b/commands/Administration/setnews.js @@ -11,6 +11,7 @@ class Setnews extends BaseCommand { command: new SlashCommandBuilder() .setName("setnews") .setDescription(client.translate("administration/setnews:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Setnews extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/setreports.js b/commands/Administration/setreports.js index 99fbd4da..02081461 100644 --- a/commands/Administration/setreports.js +++ b/commands/Administration/setreports.js @@ -11,6 +11,7 @@ class Setreports extends BaseCommand { command: new SlashCommandBuilder() .setName("setreports") .setDescription(client.translate("administration/setreports:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Setreports extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/setsuggests.js b/commands/Administration/setsuggests.js index 1af1f001..a0e32a99 100644 --- a/commands/Administration/setsuggests.js +++ b/commands/Administration/setsuggests.js @@ -11,6 +11,7 @@ class Setsuggests extends BaseCommand { command: new SlashCommandBuilder() .setName("setsuggests") .setDescription(client.translate("administration/setsuggests:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addBooleanOption(option => option.setName("state") .setDescription(client.translate("common:STATE")) @@ -20,7 +21,7 @@ class Setsuggests extends BaseCommand { .addChannelTypes(ChannelType.GuildText)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/stealemoji.js b/commands/Administration/stealemoji.js index 82bf1220..2fb38d57 100644 --- a/commands/Administration/stealemoji.js +++ b/commands/Administration/stealemoji.js @@ -11,13 +11,14 @@ class Stealemoji extends BaseCommand { command: new SlashCommandBuilder() .setName("stealemoji") .setDescription(client.translate("administration/stealemoji:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addStringOption(option => option.setName("emoji") .setDescription(client.translate("common:EMOJI")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Administration/welcome.js b/commands/Administration/welcome.js index 37f9bae5..22ea2c09 100644 --- a/commands/Administration/welcome.js +++ b/commands/Administration/welcome.js @@ -11,6 +11,7 @@ class Welcome extends BaseCommand { command: new SlashCommandBuilder() .setName("welcome") .setDescription(client.translate("administration/welcome:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ManageGuild) .addSubcommand(subcommand => subcommand.setName("test") .setDescription(client.translate("administration/goodbye:TEST")) @@ -29,7 +30,7 @@ class Welcome extends BaseCommand { ), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Economy/achievements.js b/commands/Economy/achievements.js index 76403b8c..a8f8da36 100644 --- a/commands/Economy/achievements.js +++ b/commands/Economy/achievements.js @@ -11,11 +11,11 @@ class Achievements extends BaseCommand { command: new SlashCommandBuilder() .setName("achievements") .setDescription(client.translate("economy/achievements:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/bank.js b/commands/Economy/bank.js index 05fcec36..c9900881 100644 --- a/commands/Economy/bank.js +++ b/commands/Economy/bank.js @@ -11,6 +11,7 @@ class Bank extends BaseCommand { command: new SlashCommandBuilder() .setName("bank") .setDescription(client.translate("economy/bank:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("option") .setDescription(client.translate("economy/bank:OPTION")) .setRequired(true) @@ -23,7 +24,6 @@ class Bank extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/birthdate.js b/commands/Economy/birthdate.js index 0d425772..2c53af5c 100644 --- a/commands/Economy/birthdate.js +++ b/commands/Economy/birthdate.js @@ -11,6 +11,7 @@ class Birthdate extends BaseCommand { command: new SlashCommandBuilder() .setName("birthdate") .setDescription(client.translate("economy/birthdate:DESCRIPTION")) + .setDMPermission(false) .addIntegerOption(option => option.setName("day") .setDescription(client.translate("economy/birthdate:DAY")) .setRequired(true)) @@ -36,7 +37,6 @@ class Birthdate extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/divorce.js b/commands/Economy/divorce.js index d6645993..2885c44a 100644 --- a/commands/Economy/divorce.js +++ b/commands/Economy/divorce.js @@ -10,10 +10,10 @@ class Divorce extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("divorce") - .setDescription(client.translate("economy/divorce:DESCRIPTION")), + .setDescription(client.translate("economy/divorce:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/importmee6.js b/commands/Economy/importmee6.js index ebac4149..022abc7f 100644 --- a/commands/Economy/importmee6.js +++ b/commands/Economy/importmee6.js @@ -11,10 +11,10 @@ class ImportMee6 extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("importmee6") - .setDescription(client.translate("economy/importmee6:DESCRIPTION")), + .setDescription(client.translate("economy/importmee6:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/leaderboard.js b/commands/Economy/leaderboard.js index 40bde59a..363d6c4c 100644 --- a/commands/Economy/leaderboard.js +++ b/commands/Economy/leaderboard.js @@ -19,6 +19,7 @@ class Leaderboard extends BaseCommand { command: new SlashCommandBuilder() .setName("leaderboard") .setDescription(client.translate("economy/leaderboard:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("type") .setDescription(client.translate("owner/debug:TYPE")) .setRequired(true) @@ -29,7 +30,6 @@ class Leaderboard extends BaseCommand { )), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/marry.js b/commands/Economy/marry.js index 3fe1ffde..5f27cffb 100644 --- a/commands/Economy/marry.js +++ b/commands/Economy/marry.js @@ -12,12 +12,12 @@ class Marry extends BaseCommand { command: new SlashCommandBuilder() .setName("marry") .setDescription(client.translate("economy/marry:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/money.js b/commands/Economy/money.js index 5d165343..9fde6e72 100644 --- a/commands/Economy/money.js +++ b/commands/Economy/money.js @@ -19,11 +19,11 @@ class Money extends BaseCommand { command: new SlashCommandBuilder() .setName("money") .setDescription(client.translate("economy/money:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/number.js b/commands/Economy/number.js index 59d07032..f4239713 100644 --- a/commands/Economy/number.js +++ b/commands/Economy/number.js @@ -11,10 +11,10 @@ class Number extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("number") - .setDescription(client.translate("economy/number:DESCRIPTION")), + .setDescription(client.translate("economy/number:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/pay.js b/commands/Economy/pay.js index 1ff5e8db..7c6ec732 100644 --- a/commands/Economy/pay.js +++ b/commands/Economy/pay.js @@ -11,6 +11,7 @@ class Pay extends BaseCommand { command: new SlashCommandBuilder() .setName("pay") .setDescription(client.translate("economy/pay:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)) @@ -19,7 +20,6 @@ class Pay extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/profile.js b/commands/Economy/profile.js index 8a81e9b2..29b0fb7f 100644 --- a/commands/Economy/profile.js +++ b/commands/Economy/profile.js @@ -19,11 +19,11 @@ class Profile extends BaseCommand { command: new SlashCommandBuilder() .setName("profile") .setDescription(client.translate("economy/profile:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/rep.js b/commands/Economy/rep.js index 202946b1..ee5a0c14 100644 --- a/commands/Economy/rep.js +++ b/commands/Economy/rep.js @@ -11,12 +11,12 @@ class Rep extends BaseCommand { command: new SlashCommandBuilder() .setName("rep") .setDescription(client.translate("economy/rep:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/rob.js b/commands/Economy/rob.js index 3e65de95..9acb7988 100644 --- a/commands/Economy/rob.js +++ b/commands/Economy/rob.js @@ -11,6 +11,7 @@ class Rob extends BaseCommand { command: new SlashCommandBuilder() .setName("rob") .setDescription(client.translate("economy/rob:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)) @@ -19,7 +20,6 @@ class Rob extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/setbio.js b/commands/Economy/setbio.js index ec3246e2..ee457386 100644 --- a/commands/Economy/setbio.js +++ b/commands/Economy/setbio.js @@ -11,12 +11,12 @@ class Setbio extends BaseCommand { command: new SlashCommandBuilder() .setName("setbio") .setDescription(client.translate("economy/setbio:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("text") .setDescription(client.translate("economy/profile:BIO")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/slots.js b/commands/Economy/slots.js index 36d38da0..24bb0644 100644 --- a/commands/Economy/slots.js +++ b/commands/Economy/slots.js @@ -11,12 +11,12 @@ class Slots extends BaseCommand { command: new SlashCommandBuilder() .setName("slots") .setDescription(client.translate("economy/slots:DESCRIPTION")) + .setDMPermission(false) .addIntegerOption(option => option.setName("amount") .setDescription(client.translate("common:INT")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/tictactoe.js b/commands/Economy/tictactoe.js index 41850320..65a6ac16 100644 --- a/commands/Economy/tictactoe.js +++ b/commands/Economy/tictactoe.js @@ -12,12 +12,12 @@ class TicTacToe extends BaseCommand { command: new SlashCommandBuilder() .setName("tictactoe") .setDescription(client.translate("economy/tictactoe:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/transactions.js b/commands/Economy/transactions.js index 08b7f377..57568606 100644 --- a/commands/Economy/transactions.js +++ b/commands/Economy/transactions.js @@ -11,11 +11,11 @@ class Transactions extends BaseCommand { command: new SlashCommandBuilder() .setName("transactions") .setDescription(client.translate("economy/transactions:DESCRIPTION")) + .setDMPermission(false) .addBooleanOption(option => option.setName("clear") .setDescription(client.translate("economy/transactions:CLEAR"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Economy/work.js b/commands/Economy/work.js index 6926b4ab..e10e2855 100644 --- a/commands/Economy/work.js +++ b/commands/Economy/work.js @@ -10,10 +10,10 @@ class Work extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("work") - .setDescription(client.translate("economy/work:DESCRIPTION")), + .setDescription(client.translate("economy/work:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Fun/8ball.js b/commands/Fun/8ball.js index dc56c3fb..6a058b36 100644 --- a/commands/Fun/8ball.js +++ b/commands/Fun/8ball.js @@ -11,12 +11,12 @@ class Eightball extends BaseCommand { command: new SlashCommandBuilder() .setName("8ball") .setDescription(client.translate("fun/8ball:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("question") .setDescription(client.translate("fun/8ball:QUESTION")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Fun/crab.js b/commands/Fun/crab.js index d7a89b8c..b8f02ed2 100644 --- a/commands/Fun/crab.js +++ b/commands/Fun/crab.js @@ -11,10 +11,10 @@ class Crab extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("crab") - .setDescription(client.translate("fun/crab:DESCRIPTION")), + .setDescription(client.translate("fun/crab:DESCRIPTION")) + .setDMPermission(true), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/Fun/lmgtfy.js b/commands/Fun/lmgtfy.js index 37227755..ff8c8321 100644 --- a/commands/Fun/lmgtfy.js +++ b/commands/Fun/lmgtfy.js @@ -12,6 +12,7 @@ class LMGTFY extends BaseCommand { command: new SlashCommandBuilder() .setName("lmgtfy") .setDescription(client.translate("fun/lmgtfy:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("query") .setDescription(client.translate("fun/lmgtfy:QUERY")) .setRequired(true)) @@ -20,7 +21,6 @@ class LMGTFY extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/Fun/lovecalc.js b/commands/Fun/lovecalc.js index a5d41144..4a92eb35 100644 --- a/commands/Fun/lovecalc.js +++ b/commands/Fun/lovecalc.js @@ -12,6 +12,7 @@ class Lovecalc extends BaseCommand { command: new SlashCommandBuilder() .setName("lovecalc") .setDescription(client.translate("fun/lovecalc:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("first_member") .setDescription(client.translate("common:USER")) @@ -21,7 +22,6 @@ class Lovecalc extends BaseCommand { .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Fun/memes.js b/commands/Fun/memes.js index cce63dab..c0af1d98 100644 --- a/commands/Fun/memes.js +++ b/commands/Fun/memes.js @@ -11,10 +11,10 @@ class Memes extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("memes") - .setDescription(client.translate("fun/memes:DESCRIPTION")), + .setDescription(client.translate("fun/memes:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } @@ -49,13 +49,14 @@ class Memes extends BaseCommand { .addOptions(tags) ); - await interaction.editReply({ + const msg = await interaction.editReply({ content: interaction.translate("common:AVAILABLE_OPTIONS"), + fetchReply: true, components: [row] }); const filter = i => i.user.id === interaction.user.id; - const collector = interaction.channel.createMessageComponentCollector({ filter, idle: (2 * 60 * 1000) }); + const collector = msg.createMessageComponentCollector({ filter, idle: (2 * 60 * 1000) }); collector.on("collect", async i => { if (i.isSelectMenu() && i.customId === "memes_select") { diff --git a/commands/General/activity.js b/commands/General/activity.js index d25d567a..7f35e6d4 100644 --- a/commands/General/activity.js +++ b/commands/General/activity.js @@ -11,10 +11,10 @@ class Activity extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("activity") - .setDescription(client.translate("general/activity:DESCRIPTION")), + .setDescription(client.translate("general/activity:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/afk.js b/commands/General/afk.js index 70162a80..21c1893d 100644 --- a/commands/General/afk.js +++ b/commands/General/afk.js @@ -11,12 +11,12 @@ class Afk extends BaseCommand { command: new SlashCommandBuilder() .setName("afk") .setDescription(client.translate("general/afk:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("message") .setDescription(client.translate("common:MESSAGE")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/avatar.js b/commands/General/avatar.js index a400a772..a90eb7ac 100644 --- a/commands/General/avatar.js +++ b/commands/General/avatar.js @@ -11,11 +11,11 @@ class Avatar extends BaseCommand { command: new SlashCommandBuilder() .setName("avatar") .setDescription(client.translate("general/avatar:DESCRIPTION")) + .setDMPermission(true) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/emoji.js b/commands/General/emoji.js index 1372b663..42f49e5f 100644 --- a/commands/General/emoji.js +++ b/commands/General/emoji.js @@ -11,12 +11,12 @@ class Emoji extends BaseCommand { command: new SlashCommandBuilder() .setName("emoji") .setDescription(client.translate("general/emoji:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("emoji") .setDescription(client.translate("common:EMOJI")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/help.js b/commands/General/help.js index a1c463b8..d6726fa4 100644 --- a/commands/General/help.js +++ b/commands/General/help.js @@ -11,12 +11,12 @@ class Help extends BaseCommand { command: new SlashCommandBuilder() .setName("help") .setDescription(client.translate("general/help:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("command") .setDescription(client.translate("owner/reload:COMMAND"))), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/minecraft.js b/commands/General/minecraft.js index 890f7430..19e724f5 100644 --- a/commands/General/minecraft.js +++ b/commands/General/minecraft.js @@ -12,12 +12,12 @@ class Minecraft extends BaseCommand { command: new SlashCommandBuilder() .setName("minecraft") .setDescription(client.translate("general/minecraft:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("ip") .setDescription(client.translate("common:IP")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/ping.js b/commands/General/ping.js index e50a1662..b90b7cfe 100644 --- a/commands/General/ping.js +++ b/commands/General/ping.js @@ -10,10 +10,10 @@ class Ping extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("ping") - .setDescription(client.translate("general/ping:DESCRIPTION")), + .setDescription(client.translate("general/ping:DESCRIPTION")) + .setDMPermission(true), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/remindme.js b/commands/General/remindme.js index f500e90e..f0888886 100644 --- a/commands/General/remindme.js +++ b/commands/General/remindme.js @@ -13,6 +13,7 @@ class Remindme extends BaseCommand { command: new SlashCommandBuilder() .setName("remindme") .setDescription(client.translate("general/remindme:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("time") .setDescription(client.translate("owner/remindme:TIME")) .setRequired(true)) @@ -21,7 +22,6 @@ class Remindme extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/report.js b/commands/General/report.js index 1fde346f..92393284 100644 --- a/commands/General/report.js +++ b/commands/General/report.js @@ -11,6 +11,7 @@ class Report extends BaseCommand { command: new SlashCommandBuilder() .setName("report") .setDescription(client.translate("general/report:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)) @@ -19,7 +20,6 @@ class Report extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/serverinfo.js b/commands/General/serverinfo.js index 7a39b8c5..6798e7fc 100644 --- a/commands/General/serverinfo.js +++ b/commands/General/serverinfo.js @@ -10,10 +10,10 @@ class Serverinfo extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("serverinfo") - .setDescription(client.translate("general/serverinfo:DESCRIPTION")), + .setDescription(client.translate("general/serverinfo:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/shorturl.js b/commands/General/shorturl.js index 6dbd624a..b4adc1b9 100644 --- a/commands/General/shorturl.js +++ b/commands/General/shorturl.js @@ -12,12 +12,12 @@ class Shorturl extends BaseCommand { command: new SlashCommandBuilder() .setName("shorturl") .setDescription(client.translate("general/shorturl:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("url") .setDescription(client.translate("general/shorturl:URL")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/staff.js b/commands/General/staff.js index a9947193..621ea3c4 100644 --- a/commands/General/staff.js +++ b/commands/General/staff.js @@ -10,10 +10,10 @@ class Staff extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("staff") - .setDescription(client.translate("general/staff:DESCRIPTION")), + .setDescription(client.translate("general/staff:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/stats.js b/commands/General/stats.js index d423f8dc..0800e713 100644 --- a/commands/General/stats.js +++ b/commands/General/stats.js @@ -11,10 +11,10 @@ class Stats extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("stats") - .setDescription(client.translate("general/stats:DESCRIPTION")), + .setDescription(client.translate("general/stats:DESCRIPTION")) + .setDMPermission(true), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/General/suggest.js b/commands/General/suggest.js index 77ec155c..af0f0dbf 100644 --- a/commands/General/suggest.js +++ b/commands/General/suggest.js @@ -11,12 +11,12 @@ class Suggest extends BaseCommand { command: new SlashCommandBuilder() .setName("suggest") .setDescription(client.translate("general/suggest:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("message") .setDescription(client.translate("common:MESSAGE")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/userinfo.js b/commands/General/userinfo.js index cb0e7225..57f28728 100644 --- a/commands/General/userinfo.js +++ b/commands/General/userinfo.js @@ -11,11 +11,11 @@ class Userinfo extends BaseCommand { command: new SlashCommandBuilder() .setName("userinfo") .setDescription(client.translate("general/userinfo:DESCRIPTION")) + .setDMPermission(false) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/General/whois.js b/commands/General/whois.js index a65181b7..76de6598 100644 --- a/commands/General/whois.js +++ b/commands/General/whois.js @@ -12,12 +12,12 @@ class Whois extends BaseCommand { command: new SlashCommandBuilder() .setName("whois") .setDescription(client.translate("general/whois:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("ip") .setDescription(client.translate("common:IP")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: false }); } diff --git a/commands/Moderation/clear.js b/commands/Moderation/clear.js index 0c4d8423..78b7ca1c 100644 --- a/commands/Moderation/clear.js +++ b/commands/Moderation/clear.js @@ -11,6 +11,7 @@ class Clear extends BaseCommand { command: new SlashCommandBuilder() .setName("clear") .setDescription(client.translate("moderation/clear:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addStringOption(option => option.setName("option") .setDescription(client.translate("moderation/clear:OPTION")) @@ -19,7 +20,7 @@ class Clear extends BaseCommand { .setDescription(client.translate("common:USER"))), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/clearwarns.js b/commands/Moderation/clearwarns.js index 7817e83e..80f6db2b 100644 --- a/commands/Moderation/clearwarns.js +++ b/commands/Moderation/clearwarns.js @@ -11,13 +11,14 @@ class Clearwarns extends BaseCommand { command: new SlashCommandBuilder() .setName("clearwarns") .setDescription(client.translate("moderation/clearwarns:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/giveaway.js b/commands/Moderation/giveaway.js index 856da26e..2300734a 100644 --- a/commands/Moderation/giveaway.js +++ b/commands/Moderation/giveaway.js @@ -12,6 +12,7 @@ class Giveaway extends BaseCommand { command: new SlashCommandBuilder() .setName("giveaway") .setDescription(client.translate("moderation/giveaway:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addSubcommand(subcommand => subcommand.setName("create") .setDescription(client.translate("moderation/giveaway:CREATE")) @@ -48,7 +49,7 @@ class Giveaway extends BaseCommand { ), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/poll.js b/commands/Moderation/poll.js index b14154da..d4f27050 100644 --- a/commands/Moderation/poll.js +++ b/commands/Moderation/poll.js @@ -11,13 +11,14 @@ class Poll extends BaseCommand { command: new SlashCommandBuilder() .setName("poll") .setDescription(client.translate("moderation/poll:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addStringOption(option => option.setName("question") .setDescription(client.translate("moderation/poll:QUESTION")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/unban.js b/commands/Moderation/unban.js index 11d7b9b4..89804c59 100644 --- a/commands/Moderation/unban.js +++ b/commands/Moderation/unban.js @@ -11,13 +11,14 @@ class Unban extends BaseCommand { command: new SlashCommandBuilder() .setName("unban") .setDescription(client.translate("moderation/unban:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addStringOption(option => option.setName("user_id") .setDescription(client.translate("moderation/unban:ID")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/warn.js b/commands/Moderation/warn.js index 4bd07df4..9760ab0e 100644 --- a/commands/Moderation/warn.js +++ b/commands/Moderation/warn.js @@ -11,10 +11,11 @@ class Warn extends BaseCommand { command: new ContextMenuCommandBuilder() .setName("warn") .setType(ApplicationCommandType.User) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Moderation/warns.js b/commands/Moderation/warns.js index 3efb9f99..ab897374 100644 --- a/commands/Moderation/warns.js +++ b/commands/Moderation/warns.js @@ -11,13 +11,14 @@ class Warns extends BaseCommand { command: new SlashCommandBuilder() .setName("warns") .setDescription(client.translate("moderation/warns:DESCRIPTION")) + .setDMPermission(false) .setDefaultMemberPermissions(PermissionFlagsBits.ModerateMembers && PermissionFlagsBits.ManageMessages) .addUserOption(option => option.setName("user") .setDescription(client.translate("common:USER")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true + ownerOnly: false }); } /** diff --git a/commands/Music/back.js b/commands/Music/back.js index b46212f7..b9f6db07 100644 --- a/commands/Music/back.js +++ b/commands/Music/back.js @@ -10,10 +10,10 @@ class Back extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("back") - .setDescription(client.translate("music/back:DESCRIPTION")), + .setDescription(client.translate("music/back:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/clips.js b/commands/Music/clips.js index 4e3abef5..c328b2af 100644 --- a/commands/Music/clips.js +++ b/commands/Music/clips.js @@ -12,10 +12,10 @@ class Clips extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("clips") - .setDescription(client.translate("music/clips:DESCRIPTION")), + .setDescription(client.translate("music/clips:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/loop.js b/commands/Music/loop.js index 135ae411..eab0494f 100644 --- a/commands/Music/loop.js +++ b/commands/Music/loop.js @@ -12,6 +12,7 @@ class Loop extends BaseCommand { command: new SlashCommandBuilder() .setName("loop") .setDescription(client.translate("music/loop:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("option") .setDescription(client.translate("economy/bank:OPTION")) .setRequired(true) @@ -23,7 +24,6 @@ class Loop extends BaseCommand { )), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/nowplaying.js b/commands/Music/nowplaying.js index ae6797f2..0f992ebb 100644 --- a/commands/Music/nowplaying.js +++ b/commands/Music/nowplaying.js @@ -11,10 +11,10 @@ class Nowplaying extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("nowplaying") - .setDescription(client.translate("music/nowplaying:DESCRIPTION")), + .setDescription(client.translate("music/nowplaying:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/play.js b/commands/Music/play.js index ad04fa25..23354441 100644 --- a/commands/Music/play.js +++ b/commands/Music/play.js @@ -12,12 +12,12 @@ class Play extends BaseCommand { command: new SlashCommandBuilder() .setName("play") .setDescription(client.translate("music/play:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("query") .setDescription(client.translate("music/play:QUERY")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/queue.js b/commands/Music/queue.js index 9497eba2..54b63057 100644 --- a/commands/Music/queue.js +++ b/commands/Music/queue.js @@ -11,10 +11,10 @@ class Queue extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("queue") - .setDescription(client.translate("music/queue:DESCRIPTION")), + .setDescription(client.translate("music/queue:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/shuffle.js b/commands/Music/shuffle.js index 05342315..ae0c8faa 100644 --- a/commands/Music/shuffle.js +++ b/commands/Music/shuffle.js @@ -10,10 +10,10 @@ class Shuffle extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("shuffle") - .setDescription(client.translate("music/shuffle:DESCRIPTION")), + .setDescription(client.translate("music/shuffle:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/skip.js b/commands/Music/skip.js index 02c51f3f..e35644fd 100644 --- a/commands/Music/skip.js +++ b/commands/Music/skip.js @@ -10,10 +10,10 @@ class Skip extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("skip") - .setDescription(client.translate("music/skip:DESCRIPTION")), + .setDescription(client.translate("music/skip:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/skipto.js b/commands/Music/skipto.js index 96bcea7d..6e02f341 100644 --- a/commands/Music/skipto.js +++ b/commands/Music/skipto.js @@ -11,12 +11,12 @@ class Skipto extends BaseCommand { command: new SlashCommandBuilder() .setName("skipto") .setDescription(client.translate("music/skipto:DESCRIPTION")) + .setDMPermission(false) .addIntegerOption(option => option.setName("position") .setDescription(client.translate("music/skipto:POSITION")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/Music/stop.js b/commands/Music/stop.js index 581878ad..7d259226 100644 --- a/commands/Music/stop.js +++ b/commands/Music/stop.js @@ -10,10 +10,10 @@ class Stop extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("stop") - .setDescription(client.translate("music/stop:DESCRIPTION")), + .setDescription(client.translate("music/stop:DESCRIPTION")) + .setDMPermission(false), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } diff --git a/commands/NSFW/nsfw.js b/commands/NSFW/nsfw.js index 74700372..40f14942 100644 --- a/commands/NSFW/nsfw.js +++ b/commands/NSFW/nsfw.js @@ -11,10 +11,10 @@ class NSFW extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("nsfw") - .setDescription(client.translate("nsfw/nsfw:DESCRIPTION")), + .setDescription(client.translate("nsfw/nsfw:DESCRIPTION")) + .setDMPermission(true), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: false }); } @@ -34,7 +34,7 @@ class NSFW extends BaseCommand { async execute(client, interaction) { await interaction.deferReply({ ephemeral: true }); - if (!interaction.channel.nsfw) return interaction.replyT("misc:NSFW_COMMAND", null, { ephemeral: true, edit: true }); + if ((interaction.guildId && !interaction.channel.nsfw)) return interaction.replyT("misc:NSFW_COMMAND", null, { ephemeral: true, edit: true }); const tags = ["hentai", "ecchi", "lewdanimegirls", "hentaifemdom", "animefeets", "animebooty", "biganimetiddies", "sideoppai", "ahegao"].map(tag => JSON.parse(JSON.stringify({ @@ -51,14 +51,15 @@ class NSFW extends BaseCommand { .addOptions(tags) ); - await interaction.editReply({ + const msg = await interaction.editReply({ content: interaction.translate("common:AVAILABLE_OPTIONS"), ephemeral: true, + fetchReply: true, components: [row] }); const filter = i => i.user.id === interaction.user.id; - const collector = interaction.channel.createMessageComponentCollector({ filter, idle: (2 * 60 * 1000) }); + const collector = msg.createMessageComponentCollector({ filter, idle: (2 * 60 * 1000) }); collector.on("collect", async i => { if (i.isSelectMenu() && i.customId === "nsfw_select") { diff --git a/commands/Owner/announcement.js b/commands/Owner/announcement.js index 83ac9010..b280926a 100644 --- a/commands/Owner/announcement.js +++ b/commands/Owner/announcement.js @@ -11,6 +11,7 @@ class Announcement extends BaseCommand { command: new SlashCommandBuilder() .setName("announcement") .setDescription(client.translate("owner/announcement:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("message") .setDescription(client.translate("common:MESSAGE")) .setRequired(true)) @@ -19,7 +20,6 @@ class Announcement extends BaseCommand { .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: true }); } diff --git a/commands/Owner/debug.js b/commands/Owner/debug.js index 6b6cf5d0..1dab6793 100644 --- a/commands/Owner/debug.js +++ b/commands/Owner/debug.js @@ -11,6 +11,7 @@ class Debug extends BaseCommand { command: new SlashCommandBuilder() .setName("debug") .setDescription(client.translate("owner/debug:DESCRIPTION")) + .setDMPermission(false) .addSubcommand(subcommand => subcommand.setName("set") .setDescription(client.translate("owner/debug:SET")) .addStringOption(option => option.setName("type") @@ -51,7 +52,6 @@ class Debug extends BaseCommand { ), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: true }); } diff --git a/commands/Owner/eval.js b/commands/Owner/eval.js index c70d7228..da18b8f3 100644 --- a/commands/Owner/eval.js +++ b/commands/Owner/eval.js @@ -11,12 +11,12 @@ class Eval extends BaseCommand { command: new SlashCommandBuilder() .setName("eval") .setDescription(client.translate("owner/eval:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("code") .setDescription(client.translate("owner/eval:CODE")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: true }); } diff --git a/commands/Owner/reload.js b/commands/Owner/reload.js index e57671ee..d1d096b5 100644 --- a/commands/Owner/reload.js +++ b/commands/Owner/reload.js @@ -13,12 +13,12 @@ class Reload extends BaseCommand { command: new SlashCommandBuilder() .setName("reload") .setDescription(client.translate("owner/reload:DESCRIPTION")) + .setDMPermission(true) .addStringOption(option => option.setName("command") .setDescription(client.translate("owner/reload:COMMAND")) .setRequired(true)), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: true }); } diff --git a/commands/Owner/say.js b/commands/Owner/say.js index 41df8370..98faefc0 100644 --- a/commands/Owner/say.js +++ b/commands/Owner/say.js @@ -11,6 +11,7 @@ class Say extends BaseCommand { command: new SlashCommandBuilder() .setName("say") .setDescription(client.translate("owner/say:DESCRIPTION")) + .setDMPermission(false) .addStringOption(option => option.setName("message") .setDescription(client.translate("common:MESSAGE")) .setRequired(true)) @@ -18,7 +19,6 @@ class Say extends BaseCommand { .setDescription(client.translate("common:CHANNEL"))), aliases: [], dirname: __dirname, - guildOnly: true, ownerOnly: true }); } diff --git a/commands/Owner/servers.js b/commands/Owner/servers.js index 07a9bc0a..f880f15f 100644 --- a/commands/Owner/servers.js +++ b/commands/Owner/servers.js @@ -10,10 +10,10 @@ class Servers extends BaseCommand { super({ command: new SlashCommandBuilder() .setName("servers") - .setDescription(client.translate("owner/servers:DESCRIPTION")), + .setDescription(client.translate("owner/servers:DESCRIPTION")) + .setDMPermission(true), aliases: [], dirname: __dirname, - guildOnly: false, ownerOnly: true }); } @@ -56,14 +56,15 @@ class Servers extends BaseCommand { .setEmoji("⏹️"), ); - await interaction.editReply({ + const msg = await interaction.editReply({ content: `${interaction.translate("common:PAGE")}: **${currentPage + 1}**/**${embeds.length}**`, + fetchReply: true, embeds: [embeds[currentPage]], components: [row] }); const filter = i => i.user.id === interaction.user.id; - const collector = interaction.channel.createMessageComponentCollector({ filter, idle: (20 * 1000) }); + const collector = msg.createMessageComponentCollector({ filter, idle: (20 * 1000) }); collector.on("collect", async i => { if (i.isButton()) { diff --git a/dashboard/public/docs/updates.md b/dashboard/public/docs/updates.md index 1bac1d24..55438bfa 100644 --- a/dashboard/public/docs/updates.md +++ b/dashboard/public/docs/updates.md @@ -1,3 +1,10 @@ +### JaBa v4.1.11 +* Изменения + * Команды которые нельзя использовать в ЛС с ботом не будут там отображаться. + +* Исправления + * Переписаны команды *nsfw* и *memes* для работы в ЛС с ботом. + ### JaBa v4.1.10 * Добавлено * Команда *shuffle* - Перемешать очередь. diff --git a/package.json b/package.json index 5d47866b..062d6d46 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jaba", - "version": "4.1.10", + "version": "4.1.11", "description": "My Discord Bot", "main": "index.js", "private": true,