3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-10 22:19:31 +01:00

SANICK: Fix check for new user

This commit is contained in:
Daniel Oaks 2017-06-18 08:23:51 -06:00
parent 194a301d23
commit e5980beb7d

View File

@ -94,7 +94,7 @@ func sanickHandler(server *Server, client *Client, msg ircmsg.IrcMessage) bool {
} }
//TODO(dan): There's probably some races here, we should be changing this in the primary server thread //TODO(dan): There's probably some races here, we should be changing this in the primary server thread
if server.clients.Get(nickname) != nil || server.clients.Get(nickname) != target { if server.clients.Get(nickname) != nil && server.clients.Get(nickname) != target {
client.Send(nil, server.name, ERR_NICKNAMEINUSE, client.nick, msg.Params[0], "Nickname is already in use") client.Send(nil, server.name, ERR_NICKNAMEINUSE, client.nick, msg.Params[0], "Nickname is already in use")
return false return false
} }