check_verified_properties(): Don't ignore fails of Peerstate::set_verified()

- Return Result from set_verified() so that it can't be missed.
- Pass Fingerprint to set_verified() by value to avoid cloning it inside. This optimises out an
  extra clone() if we already have a value that can be moved at the caller side. However, this may
  add an extra clone() if set_verified() fails, but let's not optimise the fail scenario.
This commit is contained in:
iequidoo
2023-01-04 22:39:29 -03:00
committed by iequidoo
parent 57d7df530b
commit 8dc6ff268d
4 changed files with 38 additions and 38 deletions

View File

@@ -368,7 +368,7 @@ impl BobState {
}
mark_peer_as_verified(
context,
self.invite.fingerprint(),
self.invite.fingerprint().clone(),
mime_message.from.addr.to_string(),
)
.await?;