fixes detection whether last argument is a username or not
This commit is contained in:
parent
ca21ce68c5
commit
4ebbcd1955
|
@ -12,7 +12,7 @@ module.exports = (bot, trigger, lib) => {
|
|||
var tmp = e.message.trim().split(' ');
|
||||
tmp.shift();
|
||||
var user = tmp[tmp.length - 1];
|
||||
if(user.match(/(\+|-)/))
|
||||
if(!(user in e.channel.names))
|
||||
user = e.user.getNick();
|
||||
else
|
||||
tmp.pop();
|
||||
|
|
Loading…
Reference in New Issue
Block a user