Merge pull request #2008 from SolarisFox/patch-6

Proper error handling in /dexsearch and /movesearch
This commit is contained in:
Guangcong Luo 2015-06-27 00:47:07 +00:00
commit 250bc0d617

View File

@ -642,7 +642,7 @@ var commands = exports.commands = {
break;
default:
return this.sendReplyBox("Something broke! PM SolarisFox here or on the Smogon forums with the command you tried.");
throw new Error("/dexsearch search category '" + search + "' was unrecognised.");
}
}
@ -1025,7 +1025,7 @@ var commands = exports.commands = {
break;
default:
return this.sendReplyBox("Something broke! PM SolarisFox here or on the Smogon forums with the command you tried.");
throw new Error("/movesearch search category '" + search + "' was unrecognised.");
}
}