Browse Source

fix #950

tags/v2.1.0-rc1
Shivaram Lingamneni 4 years ago
parent
commit
360a5af90d
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      irc/channel.go

+ 6
- 0
irc/channel.go View File

541
 
541
 
542
 func (channel *Channel) ClientHasPrivsOver(client *Client, target *Client) bool {
542
 func (channel *Channel) ClientHasPrivsOver(client *Client, target *Client) bool {
543
 	channel.stateMutex.RLock()
543
 	channel.stateMutex.RLock()
544
+	founder := channel.registeredFounder
544
 	clientModes := channel.members[client]
545
 	clientModes := channel.members[client]
545
 	targetModes := channel.members[target]
546
 	targetModes := channel.members[target]
546
 	channel.stateMutex.RUnlock()
547
 	channel.stateMutex.RUnlock()
547
 
548
 
549
+	if founder != "" && founder == client.Account() {
550
+		// #950: founder can kick or whatever without actually having the +q mode
551
+		return true
552
+	}
553
+
548
 	return channelUserModeHasPrivsOver(clientModes.HighestChannelUserMode(), targetModes.HighestChannelUserMode())
554
 	return channelUserModeHasPrivsOver(clientModes.HighestChannelUserMode(), targetModes.HighestChannelUserMode())
549
 }
555
 }
550
 
556
 

Loading…
Cancel
Save