seen: this shouldn't do anything w/privmsg
This commit is contained in:
		
							parent
							
								
									b3da273b2d
								
							
						
					
					
						commit
						ae0f56cd58
					
				| @ -21,9 +21,8 @@ class Seen(Plugin): | |||||||
|         """Hook handler functions into the IRC library.""" |         """Hook handler functions into the IRC library.""" | ||||||
| 
 | 
 | ||||||
|         self.connection.add_global_handler('pubmsg', self.handle_seeing) |         self.connection.add_global_handler('pubmsg', self.handle_seeing) | ||||||
|         self.connection.add_global_handler('privmsg', self.handle_seeing) |  | ||||||
| 
 | 
 | ||||||
|         self.connection.reactor.add_global_regex_handler(['pubmsg', 'privmsg'], r'^!seen\s+(\S+)$', self.handle_seen) |         self.connection.reactor.add_global_regex_handler(['pubmsg'], r'^!seen\s+(\S+)$', self.handle_seen) | ||||||
| 
 | 
 | ||||||
|         super(Seen, self).start() |         super(Seen, self).start() | ||||||
| 
 | 
 | ||||||
| @ -31,9 +30,8 @@ class Seen(Plugin): | |||||||
|         """Unhook handler functions into the IRC library.""" |         """Unhook handler functions into the IRC library.""" | ||||||
| 
 | 
 | ||||||
|         self.connection.remove_global_handler('pubmsg', self.handle_seeing) |         self.connection.remove_global_handler('pubmsg', self.handle_seeing) | ||||||
|         self.connection.remove_global_handler('privmsg', self.handle_seeing) |  | ||||||
| 
 | 
 | ||||||
|         self.connection.reactor.remove_global_regex_handler(['pubmsg', 'privmsg'], self.handle_seen) |         self.connection.reactor.remove_global_regex_handler(['pubmsg'], self.handle_seen) | ||||||
| 
 | 
 | ||||||
|         super(Seen, self).stop() |         super(Seen, self).stop() | ||||||
| 
 | 
 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user