This commit is contained in:
Dragon Fire
2024-04-04 23:41:29 -04:00
parent e36bc4fd8e
commit 9b17848260
+1 -1
View File
@@ -38,7 +38,7 @@ module.exports = class MorseCommand extends Command {
async run(msg, { text }) {
const translated = letterTrans(text.toLowerCase(), dictionary, ' ');
const parsed = escapeMarkdown(translated.replace(/ {2}/g, ' / '));
const connection = this.client.dispatchers.get(msg.guild.id);
const connection = msg.guild && this.client.dispatchers.get(msg.guild.id);
if (!connection) {
const usage = this.client.registry.commands.get('join').usage();
return msg.reply(stripIndents`