This commit is contained in:
Shivaram Lingamneni 2020-04-22 21:52:24 -04:00
parent a83dc6e10d
commit 360a5af90d
1 changed files with 6 additions and 0 deletions

View File

@ -541,10 +541,16 @@ func (channel *Channel) ClientPrefixes(client *Client, isMultiPrefix bool) strin
func (channel *Channel) ClientHasPrivsOver(client *Client, target *Client) bool {
channel.stateMutex.RLock()
founder := channel.registeredFounder
clientModes := channel.members[client]
targetModes := channel.members[target]
channel.stateMutex.RUnlock()
if founder != "" && founder == client.Account() {
// #950: founder can kick or whatever without actually having the +q mode
return true
}
return channelUserModeHasPrivsOver(clientModes.HighestChannelUserMode(), targetModes.HighestChannelUserMode())
}