From b4b897dd51837d028180c32da0ac775833ecc8fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Mon, 12 Apr 2021 15:19:30 +0200 Subject: [PATCH] crypto: Await the group session invalidation --- matrix_sdk_crypto/benches/crypto_bench.rs | 4 ++-- matrix_sdk_crypto/src/machine.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/matrix_sdk_crypto/benches/crypto_bench.rs b/matrix_sdk_crypto/benches/crypto_bench.rs index 6467bb65..271be9b7 100644 --- a/matrix_sdk_crypto/benches/crypto_bench.rs +++ b/matrix_sdk_crypto/benches/crypto_bench.rs @@ -222,7 +222,7 @@ pub fn room_key_sharing(c: &mut Criterion) { .unwrap(); } - machine.invalidate_group_session(&room_id); + machine.invalidate_group_session(&room_id).await.unwrap(); }) }); @@ -258,7 +258,7 @@ pub fn room_key_sharing(c: &mut Criterion) { .unwrap(); } - machine.invalidate_group_session(&room_id); + machine.invalidate_group_session(&room_id).await.unwrap(); }) }); diff --git a/matrix_sdk_crypto/src/machine.rs b/matrix_sdk_crypto/src/machine.rs index 4bb83afd..dba81260 100644 --- a/matrix_sdk_crypto/src/machine.rs +++ b/matrix_sdk_crypto/src/machine.rs @@ -1462,7 +1462,7 @@ pub(crate) mod test { .get_outbound_group_session(&room_id) .is_some()); - machine.invalidate_group_session(&room_id); + machine.invalidate_group_session(&room_id).await.unwrap(); assert!(machine .group_session_manager