From 95145fae8f1398de63284176f675553c2b725e5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Damir=20Jeli=C4=87?= Date: Wed, 16 Sep 2020 12:09:30 +0200 Subject: [PATCH] matrix-sdk: Remove the example with encrypted uploads. The example fail to build on platforms where we don't support encryption. So remove the example for now. --- matrix_sdk/src/client.rs | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/matrix_sdk/src/client.rs b/matrix_sdk/src/client.rs index aaf9c433..ddae21f2 100644 --- a/matrix_sdk/src/client.rs +++ b/matrix_sdk/src/client.rs @@ -1119,7 +1119,6 @@ impl Client { /// ```no_run /// # use std::{path::PathBuf, fs::File, io::Read}; /// # use matrix_sdk::{Client, identifiers::room_id}; - /// # use matrix_sdk_base::crypto::AttachmentEncryptor; /// # use url::Url; /// # use futures::executor::block_on; /// # block_on(async { @@ -1228,7 +1227,6 @@ impl Client { /// ```no_run /// # use std::{path::PathBuf, fs::File, io::Read}; /// # use matrix_sdk::{Client, identifiers::room_id}; - /// # use matrix_sdk_base::crypto::AttachmentEncryptor; /// # use url::Url; /// # use futures::executor::block_on; /// # block_on(async { @@ -1243,17 +1241,6 @@ impl Client { /// .expect("Can't upload my cat."); /// /// println!("Cat URI: {}", response.content_uri); - /// - /// // Upload an encrypted cat, err file. - /// let path = PathBuf::from("/home/example/my-secret-cat.jpg"); - /// let mut image = File::open(path).unwrap(); - /// let mut encryptor = AttachmentEncryptor::new(&mut image); - /// - /// let response = client - /// .upload("image/jpg", &mut encryptor) - /// .await - /// .expect("Can't upload my cat."); - /// println!("Secret cat URI: {}", response.content_uri); /// # }); /// ``` pub async fn upload(