Servers: Core objects required. Includes creation. Bump version to 0.5.0.

This commit is contained in:
Paul
2021-06-01 17:09:31 +01:00
parent a4c1fee4cc
commit bff72fa6c3
23 changed files with 415 additions and 59 deletions

View File

@@ -47,6 +47,10 @@ impl Ref {
self.fetch("channels").await
}
pub async fn fetch_server(&self) -> Result<Server> {
self.fetch("servers").await
}
pub async fn fetch_message(&self, channel: &Channel) -> Result<Message> {
let message: Message = self.fetch("messages").await?;
if &message.channel != channel.id() {