Skip to content
Snippets Groups Projects
Commit 71d1ad08 authored by Bruno Muniz's avatar Bruno Muniz :apple:
Browse files

Fixes issue where contact resets and disappears data

parent 8a8fc6fd
No related branches found
No related tags found
2 merge requests!54Releasing 1.1.4,!53Fixes restore issue disappearing data
......@@ -403,9 +403,10 @@ public final class Session: SessionType {
/// This will get called when my contact restore its contact.
/// TODO: Hold a record on the chat that this contact restored.
///
var contact = $0
contact.authStatus = .friend
_ = try? dbManager.saveContact(contact)
if var contact = try? dbManager.fetchContacts(.init(id: [$0.id])).first {
contact.authStatus = .friend
_ = try? dbManager.saveContact(contact)
}
}.store(in: &cancellables)
backupService.settingsPublisher
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment