Allow +v users to talk in +R channels.

This commit is contained in:
Alex Jaspersen 2021-06-27 19:55:47 -07:00
parent f07524111c
commit ff3f959d52
2 changed files with 3 additions and 2 deletions

View file

@ -1231,7 +1231,8 @@ func (channel *Channel) CanSpeak(client *Client) (bool, modes.Mode) {
if channel.flags.HasMode(modes.Moderated) && clientModes.HighestChannelUserMode() == modes.Mode(0) {
return false, modes.Moderated
}
if channel.flags.HasMode(modes.RegisteredOnly) && client.Account() == "" {
if channel.flags.HasMode(modes.RegisteredOnly) && client.Account() == "" &&
clientModes.HighestChannelUserMode() == modes.Mode(0) {
return false, modes.RegisteredOnly
}
if channel.flags.HasMode(modes.RegisteredOnlySpeak) && client.Account() == "" &&