don't add a self contact row when we get an offline presence from an unknown resource. Fixes #4582
This commit is contained in:
		
							parent
							
								
									5e44243758
								
							
						
					
					
						commit
						d2f1f20c1e
					
				
					 1 changed files with 3 additions and 0 deletions
				
			
		| 
						 | 
					@ -733,6 +733,9 @@ class Interface:
 | 
				
			||||||
					# Create self contact and add to roster
 | 
										# Create self contact and add to roster
 | 
				
			||||||
					if resource == conn.server_resource:
 | 
										if resource == conn.server_resource:
 | 
				
			||||||
						return
 | 
											return
 | 
				
			||||||
 | 
										# Ignore offline presence of unknown self resource
 | 
				
			||||||
 | 
										if new_show < 2:
 | 
				
			||||||
 | 
											return
 | 
				
			||||||
					contact1 = gajim.contacts.create_contact(jid=ji,
 | 
										contact1 = gajim.contacts.create_contact(jid=ji,
 | 
				
			||||||
						name=gajim.nicks[account], groups=['self_contact'],
 | 
											name=gajim.nicks[account], groups=['self_contact'],
 | 
				
			||||||
						show=array[1], status=status_message, sub='both', ask='none',
 | 
											show=array[1], status=status_message, sub='both', ask='none',
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		
		Reference in a new issue