mirror of
https://github.com/chatmail/core.git
synced 2026-05-12 19:36:32 +03:00
fix: do not ignore peerstate.save_to_db() errors
This commit is contained in:
@@ -614,7 +614,7 @@ pub(crate) async fn observe_securejoin_on_other_device(
|
|||||||
};
|
};
|
||||||
peerstate.set_verified(PeerstateKeyType::GossipKey, fingerprint, addr)?;
|
peerstate.set_verified(PeerstateKeyType::GossipKey, fingerprint, addr)?;
|
||||||
peerstate.prefer_encrypt = EncryptPreference::Mutual;
|
peerstate.prefer_encrypt = EncryptPreference::Mutual;
|
||||||
peerstate.save_to_db(&context.sql).await.unwrap_or_default();
|
peerstate.save_to_db(&context.sql).await?;
|
||||||
|
|
||||||
ChatId::set_protection_for_contact(
|
ChatId::set_protection_for_contact(
|
||||||
context,
|
context,
|
||||||
@@ -738,7 +738,7 @@ async fn mark_peer_as_verified(
|
|||||||
};
|
};
|
||||||
peerstate.set_verified(PeerstateKeyType::PublicKey, fingerprint, verifier)?;
|
peerstate.set_verified(PeerstateKeyType::PublicKey, fingerprint, verifier)?;
|
||||||
peerstate.prefer_encrypt = EncryptPreference::Mutual;
|
peerstate.prefer_encrypt = EncryptPreference::Mutual;
|
||||||
peerstate.save_to_db(&context.sql).await.unwrap_or_default();
|
peerstate.save_to_db(&context.sql).await?;
|
||||||
Ok(true)
|
Ok(true)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user