diff --git a/commands/Administration/addcommand.js b/commands/Administration/addcommand.js index 82b71c06..3a1b2856 100644 --- a/commands/Administration/addcommand.js +++ b/commands/Administration/addcommand.js @@ -33,8 +33,7 @@ class Addcommand extends Command { data.guild.save(); message.success("administration/addcommand:SUCCESS", { - commandName: name, - prefix: data.guild.prefix + commandName: name }); } } diff --git a/commands/General/quote.js b/commands/General/quote.js index 6397153d..f464a03f 100644 --- a/commands/General/quote.js +++ b/commands/General/quote.js @@ -8,7 +8,7 @@ class Quote extends Command { dirname: __dirname, enabled: true, guildOnly: true, - aliases: ["q"], + aliases: ["qu"], memberPermissions: [], botPermissions: ["SEND_MESSAGES", "EMBED_LINKS"], nsfw: false, @@ -40,12 +40,8 @@ class Quote extends Command { const msgID = args[0]; if (isNaN(msgID)) { - message.author.send({ - content: message.translate("general/quote:MISSING_ID") - }).then(() => { - message.delete(); - }).catch(() => { - message.error("misc:CANNOT_DM"); + message.error("general/quote:MISSING_ID").then(() => { + if (message.deletable) message.delete(); }); return; } @@ -54,10 +50,8 @@ class Quote extends Command { if (args[1]) { channel = this.client.channels.cache.get(args[1]); if (!channel) { - message.author.send(message.translate("general/quote:NO_MESSAGE_ID")).then(() => { - message.delete(); - }).catch(() => { - message.error("misc:CANNOT_DM"); + message.error("general/quote:NO_MESSAGE_ID").then(() => { + if (message.deletable) message.delete(); }); return; } @@ -65,31 +59,27 @@ class Quote extends Command { if (!channel) { message.channel.messages.fetch(msgID).catch(() => { - message.author.send((message.translate("general/quote:NO_MESSAGE_ID"))).then(() => { - message.delete(); - }).catch(() => { - message.error("misc:CANNOT_DM"); + message.error("general/quote:NO_MESSAGE_ID").then(() => { + if (message.deletable) message.delete(); }); return; }).then((msg) => { - message.delete(); + if (message.deletable) message.delete(); message.reply({ embeds: [embed(msg)] }); }); } else { - channel.messages.fetch(msgID).catch(() => { - message.author.send(message.translate("general/quote:NO_MESSAGE_ID")).then(() => { - message.delete(); - }).catch(() => { - message.error("misc:CANNOT_DM"); - }); - return; - }).then((msg) => { - message.delete(); + channel.messages.fetch(msgID).then((msg) => { + if (message.deletable) message.delete(); message.reply({ embeds: [embed(msg)] }); + }).catch(() => { + message.error("general/quote:NO_MESSAGE_ID").then(() => { + if (message.deletable) message.delete(); + }); + return; }); } } diff --git a/commands/Music/queue.js b/commands/Music/queue.js index fc6fcc59..972f0768 100644 --- a/commands/Music/queue.js +++ b/commands/Music/queue.js @@ -9,7 +9,7 @@ class Queue extends Command { dirname: __dirname, enabled: true, guildOnly: true, - aliases: ["qu"], + aliases: ["q"], memberPermissions: [], botPermissions: ["SEND_MESSAGES", "EMBED_LINKS"], nsfw: false, diff --git a/events/messageCreate.js b/events/messageCreate.js index aeb5257b..b8b70859 100644 --- a/events/messageCreate.js +++ b/events/messageCreate.js @@ -121,7 +121,7 @@ module.exports = class { })); } - if (customCommandAnswer) return message.channel.send({ content: customCommandAnswer }); + if (customCommandAnswer) return message.channel.send({ content: customCommandAnswer.replace("{user}", message.author).replace("{guild}", message.guild) }); if (cmd.conf.guildOnly && !message.guild) return message.error("misc:GUILD_ONLY"); if (message.guild) { diff --git a/languages/ru-RU/administration/addcommand.json b/languages/ru-RU/administration/addcommand.json index 64e97322..d3b3be19 100644 --- a/languages/ru-RU/administration/addcommand.json +++ b/languages/ru-RU/administration/addcommand.json @@ -1,8 +1,8 @@ { "DESCRIPTION": "Создать свою команду!", "USAGE": "{{prefix}}addcommand [название] [ответ]", - "EXAMPLES": "{{prefix}}addcommand hello Привет, {user}!", + "EXAMPLES": "{{prefix}}addcommand hello Привет, {user}. Добро пожаловать на {guild}!", "MISSING_NAME": "Укажите название команды!", "MISSING_ANSWER": "Укажите ответ команды!", - "SUCCESS": "Команда **{{prefix}}{{commandName}}** создана!" + "SUCCESS": "Команда **{{commandName}}** создана!" } \ No newline at end of file diff --git a/languages/ru-RU/administration/delcommand.json b/languages/ru-RU/administration/delcommand.json index ca73e4f9..12e1f9c9 100644 --- a/languages/ru-RU/administration/delcommand.json +++ b/languages/ru-RU/administration/delcommand.json @@ -4,5 +4,5 @@ "EXAMPLES": "{{prefix}}delcommand hello", "MISSING_NAME": "Введите название команды!", "UNKNOWN_COMMAND": "Команда {{commandName}} не существует!", - "SUCCESS": "Команда {{commandName}} была удалена с сервера!" + "SUCCESS": "Команда **{{commandName}}** была удалена с сервера!" } \ No newline at end of file diff --git a/languages/ru-RU/general/help.json b/languages/ru-RU/general/help.json index c8e7f88d..a62ab476 100644 --- a/languages/ru-RU/general/help.json +++ b/languages/ru-RU/general/help.json @@ -11,7 +11,7 @@ "NO_ALIAS": "Нет сокращений", "CMD_TITLE": "Помощь по {{cmd}}", "INFO": "● Чтобы получить помощь по определённой команде используйте `{{prefix}}help <команда>`!", - "CUSTOM_COMMANDS": "Добавленная команда", + "CUSTOM_COMMANDS": "Добавленные команды", "FIELD_PERMISSIONS": "Необходимые права", "NO_REQUIRED_PERMISSION": "Никаких особых прав не нужно для использования данной команды.", "TITLE": "{{name}} | Команды" diff --git a/languages/uk-UA/administration/addcommand.json b/languages/uk-UA/administration/addcommand.json index 66c13f36..8483d9b6 100644 --- a/languages/uk-UA/administration/addcommand.json +++ b/languages/uk-UA/administration/addcommand.json @@ -1,7 +1,7 @@ { "DESCRIPTION": "Створити власну команду!", "USAGE": "{{prefix}}addcommand [назва] [відповідь]", - "EXAMPLES": "{{prefix}}addcommand hello Привіт, {user}!", + "EXAMPLES": "{{prefix}}addcommand hello Привіт, {user}. Добро пожаловать на {guild}!", "MISSING_NAME": "Укажіть назву команди!", "MISSING_ANSWER": "Укажіть відповідь команди!", "SUCCESS": "Команда **{{prefix}}{{commandName}}** створена!"