3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-15 00:19:29 +01:00

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

@ -815,7 +815,7 @@ If this mode is unset, users who aren't on your channel can send messages to it.
If this mode is set, only users that have logged into an account will be able to join and speak on the channel. If this is set and a regular, un-logged-in user tries to join, they will be rejected.
Unregistered users already joined to the channel will no longer be able to send messages to it, but they will not be kicked automatically. If they leave, they would not be allowed to rejoin.
Unregistered users already joined to the channel will not be kicked automatically. They will no longer be able to send messages to the channel, unless they have been voiced (+v). If they leave, they would not be allowed to rejoin.
To set this mode:

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() == "" &&