Add maintenance mode check in play command

This commit is contained in:
Christer Warén 2021-09-09 18:53:46 +03:00
parent 9c3748ad7c
commit 22c0544d09

View File

@ -14,6 +14,15 @@ module.exports = {
category: "radio", category: "radio",
async execute(interaction, client) { async execute(interaction, client) {
let message = {}; let message = {};
if(client.config.maintenance){
interaction.reply({
content: client.messageEmojis["error"] + client.messages.maintenance,
ephemeral: true
});
return false;
}
if(!client.stations) { if(!client.stations) {
message.errorToGetPlaylist = client.messages.errorToGetPlaylist.replace("%client.config.supportGuild%", client.config.supportGuild); message.errorToGetPlaylist = client.messages.errorToGetPlaylist.replace("%client.config.supportGuild%", client.config.supportGuild);
return interaction.reply({ return interaction.reply({