Catch every API

This commit is contained in:
Daniel Odendahl Jr
2017-08-27 22:04:58 +00:00
parent 75422711c3
commit eed39c5ec1
63 changed files with 785 additions and 631 deletions
+2 -2
View File
@@ -22,9 +22,9 @@ module.exports = class MathCommand extends Command {
const { expression } = args;
try {
const solved = math.eval(expression).toString();
return msg.say(solved).catch(() => msg.say('Invalid Statement'));
return msg.say(solved).catch(() => msg.say('Invalid statement.'));
} catch (err) {
return msg.say('Invalid Statement');
return msg.say('Invalid statement.');
}
}
};