Skip to content

Commit

Permalink
Merge pull request #2145 from slingamn/issue2144
Browse files Browse the repository at this point in the history
fix #2144
  • Loading branch information
slingamn authored Apr 15, 2024
2 parents 74fa04c + f96f918 commit 40ceb49
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion irc/channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,10 @@ func (channel *Channel) Names(client *Client, rb *ResponseBuffer) {
chname := channel.name
membersCache, memberDataCache := channel.membersCache, channel.memberDataCache
channel.stateMutex.RUnlock()
symbol := "=" // https://modern.ircdocs.horse/#rplnamreply-353
if channel.flags.HasMode(modes.Secret) {
symbol = "@"
}
isOper := client.HasRoleCapabs("sajoin")
respectAuditorium := channel.flags.HasMode(modes.Auditorium) && !isOper &&
(!isJoined || clientData.modes.HighestChannelUserMode() == modes.Mode(0))
Expand Down Expand Up @@ -478,7 +482,7 @@ func (channel *Channel) Names(client *Client, rb *ResponseBuffer) {
}

for _, line := range tl.Lines() {
rb.Add(nil, client.server.name, RPL_NAMREPLY, client.nick, "=", chname, line)
rb.Add(nil, client.server.name, RPL_NAMREPLY, client.nick, symbol, chname, line)
}
rb.Add(nil, client.server.name, RPL_ENDOFNAMES, client.nick, chname, client.t("End of NAMES list"))
}
Expand Down

0 comments on commit 40ceb49

Please sign in to comment.