From 6ca9632a628e542e24682a5f5d1cdfb4c25eda46 Mon Sep 17 00:00:00 2001 From: Chris Johnston Date: Tue, 27 Mar 2018 01:12:47 -0700 Subject: [PATCH] Add throw for GetCategoryAsync --- src/Discord.Net.Rest/Entities/Channels/RestCategoryChannel.cs | 2 ++ .../Entities/Channels/SocketCategoryChannel.cs | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/Discord.Net.Rest/Entities/Channels/RestCategoryChannel.cs b/src/Discord.Net.Rest/Entities/Channels/RestCategoryChannel.cs index 2a89edb37..bfcfa1a92 100644 --- a/src/Discord.Net.Rest/Entities/Channels/RestCategoryChannel.cs +++ b/src/Discord.Net.Rest/Entities/Channels/RestCategoryChannel.cs @@ -27,6 +27,8 @@ namespace Discord.Rest // IGuildChannel ulong? IGuildChannel.CategoryId => throw new NotSupportedException(); + Task IGuildChannel.GetCategoryAsync() + => throw new NotSupportedException(); IAsyncEnumerable> IGuildChannel.GetUsersAsync(CacheMode mode, RequestOptions options) => throw new NotSupportedException(); Task IGuildChannel.GetUserAsync(ulong id, CacheMode mode, RequestOptions options) diff --git a/src/Discord.Net.WebSocket/Entities/Channels/SocketCategoryChannel.cs b/src/Discord.Net.WebSocket/Entities/Channels/SocketCategoryChannel.cs index 9986ebf9c..384620d22 100644 --- a/src/Discord.Net.WebSocket/Entities/Channels/SocketCategoryChannel.cs +++ b/src/Discord.Net.WebSocket/Entities/Channels/SocketCategoryChannel.cs @@ -53,6 +53,8 @@ namespace Discord.WebSocket // IGuildChannel ulong? IGuildChannel.CategoryId => throw new NotSupportedException(); + Task IGuildChannel.GetCategoryAsync() + => throw new NotSupportedException(); IAsyncEnumerable> IGuildChannel.GetUsersAsync(CacheMode mode, RequestOptions options) => ImmutableArray.Create>(Users).ToAsyncEnumerable(); Task IGuildChannel.GetUserAsync(ulong id, CacheMode mode, RequestOptions options)