- if (match && match[1] == 'me') {
- message = "* " + rcnick() + " " + match[2];
- } else if (match && match[1] == 'nick') {
- message = "*** " + rcnick() + " is now known as " + match[2];
- rcsetnick(match[2]);
+ if (match) {
+ if (match[1] == 'me') {
+ message = "* " + rcnick() + " " + match[2];
+ } else if (match[1] == 'nick') {
+ message = "*** " + rcnick() + " is now known as " + match[2];
+ rcsetnick(match[2]);
+ } else {
+ rcaddmessagetoUI({'Text': '-!- No such command: ' + match[1], 'ServerTimes': {}});
+ return;
+ }