Merge pull request #176 from lbryio/bugfix-vars

Fixed problem with aliases causing bot to crash
This commit is contained in:
filipnyquist 2018-05-30 18:45:12 +02:00 committed by GitHub
commit 61198288fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -101,11 +101,11 @@ function checkMessageForCommand(msg, isEdit) {
}
}
let alias = aliases[cmdTxt];
let cmd;
if (alias) {
let cmd = alias;
cmd = alias;
} else {
let cmd = commands[cmdTxt];
cmd = commands[cmdTxt];
}
if (cmdTxt === 'help') {
//help is special since it iterates over the other commands