From e5980beb7da20d3df6d9b6bc60b2e4fda865f23c Mon Sep 17 00:00:00 2001 From: Daniel Oaks Date: Sun, 18 Jun 2017 08:23:51 -0600 Subject: [PATCH] SANICK: Fix check for new user --- irc/nickname.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/irc/nickname.go b/irc/nickname.go index 4978fc1e..97cb40b5 100644 --- a/irc/nickname.go +++ b/irc/nickname.go @@ -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 - 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") return false }