update avatar files when we update our vcard
This commit is contained in:
		
							parent
							
								
									f57cd7b0d3
								
							
						
					
					
						commit
						be246e984d
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -854,6 +854,8 @@ class ConnectionVcard:
 | 
			
		|||
		vcard['PHOTO'].has_key('BINVAL'):
 | 
			
		||||
			photo = vcard['PHOTO']['BINVAL']
 | 
			
		||||
			photo_decoded = base64.decodestring(photo)
 | 
			
		||||
			our_jid = gajim.get_jid_from_account(self.name)
 | 
			
		||||
			gajim.interface.save_avatar_files(our_jid, photo_decoded)
 | 
			
		||||
			avatar_sha = sha.sha(photo_decoded).hexdigest()
 | 
			
		||||
			iq2.getTag('PHOTO').setTagData('SHA', avatar_sha)
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		
		Reference in a new issue