mirror of
				https://github.com/jlu5/PyLink.git
				synced 2025-11-04 08:57:25 +01:00 
			
		
		
		
	relay: also send internal hook for services login, for integration with automode
This commit is contained in:
		
							parent
							
								
									0d502095c5
								
							
						
					
					
						commit
						b3310eaf78
					
				@ -232,3 +232,4 @@ def handle_services_login(irc, source, command, args):
 | 
			
		||||
        match(irc, channel, source)
 | 
			
		||||
 | 
			
		||||
utils.add_hook(handle_services_login, 'CLIENT_SERVICES_LOGIN')
 | 
			
		||||
utils.add_hook(handle_services_login, 'PYLINK_RELAY_SERVICES_LOGIN')
 | 
			
		||||
 | 
			
		||||
@ -1313,6 +1313,15 @@ def handle_endburst(irc, numeric, command, args):
 | 
			
		||||
        initializeAll(irc)
 | 
			
		||||
utils.add_hook(handle_endburst, "ENDBURST")
 | 
			
		||||
 | 
			
		||||
def handle_services_login(irc, numeric, command, args):
 | 
			
		||||
    """
 | 
			
		||||
    Relays services account changes as a hook, for integration with plugins like Automode.
 | 
			
		||||
    """
 | 
			
		||||
    for netname, user in relayusers[(irc.name, numeric)].items():
 | 
			
		||||
        remoteirc = world.networkobjects[netname]
 | 
			
		||||
        remoteirc.callHooks([user, 'PYLINK_RELAY_SERVICES_LOGIN', args])
 | 
			
		||||
utils.add_hook(handle_services_login, 'CLIENT_SERVICES_LOGIN')
 | 
			
		||||
 | 
			
		||||
def handle_disconnect(irc, numeric, command, args):
 | 
			
		||||
    """Handles IRC network disconnections (internal hook)."""
 | 
			
		||||
    # Quit all of our users' representations on other nets, and remove
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user