Использовать стандартное сообщение если не указано

This commit is contained in:
JonnyBro 2022-08-14 23:07:44 +05:00
parent fe0506ea98
commit c8ab14a59c
2 changed files with 2 additions and 2 deletions

View file

@ -67,7 +67,7 @@ class Goodbye extends BaseCommand {
interaction.success("administration/goodbye:DISABLED"); interaction.success("administration/goodbye:DISABLED");
} else { } else {
const channel = interaction.options.getChannel("channel"); const channel = interaction.options.getChannel("channel");
const message = interaction.options.getString("message"); const message = interaction.options.getString("message") || interaction.translate("administration/goodbye:DEFAULT_MESSAGE");
const image = interaction.options.getBoolean("image"); const image = interaction.options.getBoolean("image");
data.guildData.plugins.goodbye = { data.guildData.plugins.goodbye = {

View file

@ -67,7 +67,7 @@ class Welcome extends BaseCommand {
interaction.success("administration/welcome:DISABLED"); interaction.success("administration/welcome:DISABLED");
} else { } else {
const channel = interaction.options.getChannel("channel"); const channel = interaction.options.getChannel("channel");
const message = interaction.options.getString("message"); const message = interaction.options.getString("message") || interaction.translate("administration/welcome:DEFAULT_MESSAGE");
const image = interaction.options.getBoolean("image"); const image = interaction.options.getBoolean("image");
data.guildData.plugins.welcome = { data.guildData.plugins.welcome = {