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

channel: Server opers shouldn't override nooutside, reggedonly and moderated modes. if they want to do that sort of thing, they have SAMODE and all to be explicit about it

This commit is contained in:
Daniel Oaks 2017-10-01 15:18:52 +10:00
parent e3a0387cf5
commit b8d47c3e4f

View File

@ -425,11 +425,6 @@ func (channel *Channel) CanSpeak(client *Client) bool {
channel.membersMutex.RLock()
defer channel.membersMutex.RUnlock()
// server operators override nooutside, reggedonly, moderated etc.
// TODO(dan): there should probably instead be a SAPRIVMSG instead that forces this instead of doing it this way...
if client.flags[Operator] {
return true
}
if channel.flags[NoOutside] && !channel.members.Has(client) {
return false
}