mirror of
https://github.com/ergochat/ergo.git
synced 2024-12-22 18:52:41 +01:00
allow nick changing
This commit is contained in:
parent
39911a812d
commit
4df8ec12f6
@ -23,7 +23,7 @@ var (
|
|||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
SEM_VER = "ergonomadic-1.2.4"
|
SEM_VER = "ergonomadic-1.2.5"
|
||||||
CRLF = "\r\n"
|
CRLF = "\r\n"
|
||||||
MAX_REPLY_LEN = 512 - len(CRLF)
|
MAX_REPLY_LEN = 512 - len(CRLF)
|
||||||
|
|
||||||
|
@ -411,7 +411,8 @@ func (msg *NickCommand) HandleServer(server *Server) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if server.clients.Get(msg.nickname) != client {
|
target := server.clients.Get(msg.nickname)
|
||||||
|
if (target != nil) && (target != client) {
|
||||||
client.ErrNickNameInUse(msg.nickname)
|
client.ErrNickNameInUse(msg.nickname)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user