3
0
mirror of https://github.com/reality/dbot.git synced 2025-01-23 18:44:14 +01:00

Stop alias if already exists in user

This commit is contained in:
Luke Slater 2012-12-29 16:01:03 +01:00
parent 1cc83dc6bc
commit e7addd9ff4

View File

@ -45,7 +45,9 @@ var users = function(dbot) {
} }
} else if(event.action == 'NICK') { } else if(event.action == 'NICK') {
var newNick = event.params.substr(1); var newNick = event.params.substr(1);
knownUsers.aliases[newNick] = event.user; if(!knownUsers.users.include(newNick)) {
knownUsers.aliases[newNick] = event.user;
}
} }
}, },
'on': ['JOIN', 'NICK'], 'on': ['JOIN', 'NICK'],