Avatar is deleted when updating vCard
Versions
- OS: Arch Linux
- Gajim version: gajim master (cf911b39)
Steps to reproduce the problem
- Set an avatar in your contacts profile
- Go to Accounts - Profile
- (optional: change anything - except the avatar)
- Select "Ok"
Expected behavior
Profile is updated on Server.
Actual behavior
Profile is updated but avatar is deleted (i.e. not resend to the server on vCard update, see XML Console).
According to XEP-0054 the entire vCard must be sent to the server to update any part.
I debugged gajim and i guess this is the code line where the avatar is omitted from the vCard: https://dev.gajim.org/gajim/gajim/blob/master/gajim/profile_window.py#L323 The variable self.avatar_encoded is only set when actually updating the avatar in the profile window, so it gets omitted when anything else is changed.