Clean-ups

This commit is contained in:
Daniel Odendahl Jr
2017-08-16 16:06:06 +00:00
parent df12a04489
commit 218c8aa0fa
43 changed files with 98 additions and 127 deletions
+2 -3
View File
@@ -15,7 +15,7 @@ module.exports = class MorseCommand extends Command {
prompt: 'What text would you like to convert to morse?',
type: 'string',
validate: text => {
if (letterTrans(text, dictionary, ' ').length < 1999) return true;
if (letterTrans(text, dictionary, ' ').length < 2000) return true;
return 'Your text is too long.';
}
}
@@ -25,7 +25,6 @@ module.exports = class MorseCommand extends Command {
run(msg, args) {
const { text } = args;
const converted = letterTrans(text.toLowerCase(), dictionary, ' ');
return msg.say(converted);
return msg.say(letterTrans(text.toLowerCase(), dictionary, ' '));
}
};