feature: Add GetCategory method (#1261)

This commit is contained in:
Still Hsu
2019-05-05 05:07:56 +08:00
committed by Christopher F
parent 9084c4214e
commit e03c5274f8

View File

@@ -520,6 +520,15 @@ namespace Discord.WebSocket
/// </returns>
public SocketVoiceChannel GetVoiceChannel(ulong id)
=> GetChannel(id) as SocketVoiceChannel;
/// <summary>
/// Gets a category channel in this guild.
/// </summary>
/// <param name="id">The snowflake identifier for the category channel.</param>
/// <returns>
/// A category channel associated with the specified <paramref name="id" />; <c>null</c> if none is found.
/// </returns>
public SocketCategoryChannel GetCategoryChannel(ulong id)
=> GetChannel(id) as SocketCategoryChannel;
/// <summary>
/// Creates a new text channel in this guild.