From 8be8f0f08d8489aa4e737e648e31f8497c5ad617 Mon Sep 17 00:00:00 2001 From: Shivaram Lingamneni Date: Tue, 7 Dec 2021 01:31:07 -0500 Subject: [PATCH] fix #1858 The channel mode +R used to both prevent joins by unregistered users, and prevent unregistered users who happened to be joined from speaking. This changes the behavior so that +R only prevents joins: 1. This allows users who were invited or SAJOIN'ed to speak 2. To restore the old semantics, chanops can set +RM --- irc/channel.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/irc/channel.go b/irc/channel.go index 91a82a5a..6537537d 100644 --- a/irc/channel.go +++ b/irc/channel.go @@ -1236,10 +1236,6 @@ 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() == "" && - clientModes.HighestChannelUserMode() == modes.Mode(0) { - return false, modes.RegisteredOnly - } if channel.flags.HasMode(modes.RegisteredOnlySpeak) && client.Account() == "" && clientModes.HighestChannelUserMode() == modes.Mode(0) { return false, modes.RegisteredOnlySpeak