vaegram 0.3.0

Telegram MTProto client library for users and bots
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use crate::Client;
use crate::errors::Result;
use crate::raw::functions;
use crate::types::Folder;

impl Client {
    /// Saves `folder` under its `id`, replacing the folder that has that id.
    pub async fn edit_folder(&self, folder: &Folder) -> Result<()> {
        let filter = Some(folder.write(self).await?);
        self.invoke(&functions::messages::UpdateDialogFilter { id: folder.id, filter }).await?;
        Ok(())
    }
}