From f603696ff4bc8b174b99ac5dc87ea508ca3735e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Fri, 11 Sep 2020 17:06:45 +0200 Subject: [PATCH] crypto: Expose the olm machine only if the encryption feature is enabled. --- matrix_sdk_base/src/client.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/matrix_sdk_base/src/client.rs b/matrix_sdk_base/src/client.rs index 57c2c1ab..ff91cfcd 100644 --- a/matrix_sdk_base/src/client.rs +++ b/matrix_sdk_base/src/client.rs @@ -1862,6 +1862,8 @@ impl BaseClient { } /// Get the olm machine. + #[cfg(feature = "encryption")] + #[cfg_attr(feature = "docs", doc(cfg(encryption)))] pub async fn olm_machine(&self) -> Option { let olm = self.olm.lock().await; olm.as_ref().cloned()