diff --git a/crates/matrix-sdk-crypto/src/olm/account.rs b/crates/matrix-sdk-crypto/src/olm/account.rs index 67af1d7f4..4372e74fb 100644 --- a/crates/matrix-sdk-crypto/src/olm/account.rs +++ b/crates/matrix-sdk-crypto/src/olm/account.rs @@ -866,7 +866,7 @@ impl ReadOnlyAccount { let one_time_keys = self.one_time_keys().await; let mut one_time_key_map = BTreeMap::new(); - for (key_id, key) in one_time_keys.curve25519().iter() { + for (key_id, key) in one_time_keys.curve25519() { let key_json = json!({ "key": key, }); diff --git a/crates/matrix-sdk-crypto/src/store/sled.rs b/crates/matrix-sdk-crypto/src/store/sled.rs index 8b1ba4e12..5c87d723b 100644 --- a/crates/matrix-sdk-crypto/src/store/sled.rs +++ b/crates/matrix-sdk-crypto/src/store/sled.rs @@ -424,7 +424,7 @@ impl SledStore { } async fn load_tracked_users(&self) -> Result<()> { - for value in self.tracked_users.iter() { + for value in &self.tracked_users { let (user, dirty) = value?; let user = Box::::try_from(String::from_utf8_lossy(&user).to_string())?; let dirty = dirty.get(0).map(|d| *d == 1).unwrap_or(true); diff --git a/crates/matrix-sdk-crypto/src/verification/sas/helpers.rs b/crates/matrix-sdk-crypto/src/verification/sas/helpers.rs index c7df219c1..4e50b193f 100644 --- a/crates/matrix-sdk-crypto/src/verification/sas/helpers.rs +++ b/crates/matrix-sdk-crypto/src/verification/sas/helpers.rs @@ -606,8 +606,8 @@ mod test { fn proptest_emoji(bytes in prop::array::uniform6(0u8..)) { let numbers = bytes_to_emoji_index(bytes.to_vec()); - for number in numbers.iter() { - prop_assert!(*number < 64); + for number in numbers { + prop_assert!(number < 64); } } }