aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/model/guild.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/model/guild.rs b/src/model/guild.rs
index 9af9e00..7dd72d9 100644
--- a/src/model/guild.rs
+++ b/src/model/guild.rs
@@ -1112,6 +1112,12 @@ impl Guild {
}
impl GuildId {
+ /// Converts the guild Id into the default channel's Id.
+ #[inline]
+ pub fn as_channel_id(&self) -> ChannelId {
+ ChannelId(self.0)
+ }
+
/// Ban a [`User`] from the guild. All messages by the
/// user within the last given number of days given will be deleted.
///