mirror of
				https://github.com/jlu5/PyLink.git
				synced 2025-11-04 08:57:25 +01:00 
			
		
		
		
	Irc.applyModes: assume modes are being added if no +/- is given
This commit is contained in:
		
							parent
							
								
									ce95e15897
								
							
						
					
					
						commit
						33034b23f1
					
				@ -639,7 +639,7 @@ class Irc():
 | 
			
		||||
                              'it\'s a prefix mode.', self.name, str(mode))
 | 
			
		||||
                    continue
 | 
			
		||||
 | 
			
		||||
            if mode[0][0] == '+':
 | 
			
		||||
            if mode[0][0] != '-':
 | 
			
		||||
                # We're adding a mode
 | 
			
		||||
                existing = [m for m in modelist if m[0] == real_mode[0] and m[1] != real_mode[1]]
 | 
			
		||||
                if existing and real_mode[1] and real_mode[0] not in self.cmodes['*A']:
 | 
			
		||||
@ -663,7 +663,6 @@ class Irc():
 | 
			
		||||
                        if oldmode[0] == real_mode[0]:
 | 
			
		||||
                            modelist.discard(oldmode)
 | 
			
		||||
                else:
 | 
			
		||||
                    # Swap the - for a + and then remove it from the list.
 | 
			
		||||
                    modelist.discard(real_mode)
 | 
			
		||||
        log.debug('(%s) Final modelist: %s', self.name, modelist)
 | 
			
		||||
        if usermodes:
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user