mirror of
https://github.com/ergochat/ergo.git
synced 2025-12-20 10:10:08 -08:00
loosen restrictions on WHO replies
This commit is contained in:
parent
f9bf422ba7
commit
c8701febd0
1 changed files with 9 additions and 3 deletions
|
|
@ -562,16 +562,22 @@ func (msg *WhoCommand) HandleServer(server *Server) {
|
||||||
mask := string(msg.mask)
|
mask := string(msg.mask)
|
||||||
if mask == "" {
|
if mask == "" {
|
||||||
for _, channel := range server.channels {
|
for _, channel := range server.channels {
|
||||||
whoChannel(client, channel)
|
for member := range channel.members {
|
||||||
|
if !client.flags[Invisible] {
|
||||||
|
client.RplWhoReply(channel, member)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else if IsChannel(mask) {
|
} else if IsChannel(mask) {
|
||||||
channel := server.channels[mask]
|
channel := server.channels[mask]
|
||||||
if channel != nil {
|
if channel != nil {
|
||||||
whoChannel(client, channel)
|
for member := range channel.members {
|
||||||
|
client.RplWhoReply(channel, member)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
mclient := server.clients[mask]
|
mclient := server.clients[mask]
|
||||||
if mclient != nil && !mclient.flags[Invisible] {
|
if mclient != nil {
|
||||||
client.RplWhoReply(nil, mclient)
|
client.RplWhoReply(nil, mclient)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue