use crate::Client;
use crate::errors::Result;
use crate::raw::functions;
use crate::types::PeerRef;
impl Client {
/// Replaces the description of a group or channel.
pub async fn set_chat_description(
&self,
chat_id: impl Into<PeerRef>,
description: impl Into<String>,
) -> Result<()> {
let peer = self.resolve_peer(chat_id).await?;
self.invoke(&functions::messages::EditChatAbout { peer, about: description.into() }).await?;
Ok(())
}
}