mirror of
https://git.jami.net/savoirfairelinux/jami-client-qt.git
synced 2025-09-10 12:03:18 +02:00
profile: vcard: fix add deletion logic check
If you are deleting a conversation with yourself, you should not delete your own vCard. This will cause your profile picture to be removed, among other things. GitLab: #1838 Change-Id: I2e6ec3e941e6fdef1bf9df24238e720a73aba6dd
This commit is contained in:
parent
560f44f6f1
commit
f489f21271
1 changed files with 5 additions and 1 deletions
|
@ -887,7 +887,11 @@ ContactModelPimpl::slotContactRemoved(const QString& accountId,
|
|||
}
|
||||
}
|
||||
storage::removeContactConversations(db, contactUri);
|
||||
storage::removeProfile(linked.owner.id, contactUri);
|
||||
if (linked.owner.profileInfo.uri != contactUri) {
|
||||
// Add check to not remove your own vcard if you're deleting
|
||||
// a conversation with yourself.
|
||||
storage::removeProfile(linked.owner.id, contactUri);
|
||||
}
|
||||
contacts.remove(contactUri);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue