mirror of
https://github.com/ergochat/ergo.git
synced 2025-12-20 02:00:11 -08:00
fix #394
This commit is contained in:
parent
3d89c70c49
commit
a5b9634783
4 changed files with 40 additions and 20 deletions
|
|
@ -63,13 +63,15 @@ func sendRoleplayMessage(server *Server, client *Client, source string, targetSt
|
|||
return
|
||||
}
|
||||
|
||||
user.Send(nil, source, "PRIVMSG", user.nick, message)
|
||||
cnick := client.Nick()
|
||||
tnick := user.Nick()
|
||||
user.Send(nil, source, "PRIVMSG", tnick, message)
|
||||
if client.capabilities.Has(caps.EchoMessage) {
|
||||
rb.Add(nil, source, "PRIVMSG", user.nick, message)
|
||||
rb.Add(nil, source, "PRIVMSG", tnick, message)
|
||||
}
|
||||
if user.HasMode(modes.Away) {
|
||||
//TODO(dan): possibly implement cooldown of away notifications to users
|
||||
rb.Add(nil, server.name, RPL_AWAY, user.nick, user.awayMessage)
|
||||
rb.Add(nil, server.name, RPL_AWAY, cnick, tnick, user.AwayMessage())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue