Fixed an index out of range error that occurs when a client without a nick sends a USER command.
This commit is contained in:
parent
cc79e22ffe
commit
64e72362d9
@ -111,7 +111,7 @@ func (s *Server) handleCommand(client *Client, command string, args []string) {
|
||||
|
||||
case "USER":
|
||||
if client.nick == "" {
|
||||
client.reply(rplKill, "Your nickname is already being used")
|
||||
client.reply(rplKill, "Your nickname is already being used", "")
|
||||
client.disconnect()
|
||||
} else {
|
||||
client.reply(rplWelcome)
|
||||
|
Loading…
Reference in New Issue
Block a user