From 6b034af1d0f4a88efa0a577450a456d6e9f1f14e Mon Sep 17 00:00:00 2001
From: Still Hsu <341464@gmail.com>
Date: Sat, 9 Feb 2019 06:12:16 +0800
Subject: [PATCH] Add GetCategory method
---
src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs b/src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs
index ca2db1a77c..955e219af1 100644
--- a/src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs
+++ b/src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs
@@ -520,6 +520,15 @@ public SocketTextChannel GetTextChannel(ulong id)
///
public SocketVoiceChannel GetVoiceChannel(ulong id)
=> GetChannel(id) as SocketVoiceChannel;
+ ///
+ /// Gets a category channel in this guild.
+ ///
+ /// The snowflake identifier for the category channel.
+ ///
+ /// A category channel associated with the specified ; null if none is found.
+ ///
+ public SocketCategoryChannel GetCategoryChannel(ulong id)
+ => GetChannel(id) as SocketCategoryChannel;
///
/// Creates a new text channel in this guild.