| @@ -12,6 +12,8 @@ namespace Discord | |||||
| /// <summary> The channel is a group channel. </summary> | /// <summary> The channel is a group channel. </summary> | ||||
| Group = 3, | Group = 3, | ||||
| /// <summary> The channel is a category channel. </summary> | /// <summary> The channel is a category channel. </summary> | ||||
| Category = 4 | |||||
| Category = 4, | |||||
| /// <summary> The channel is a news channel. </summary> | |||||
| News = 5 | |||||
| } | } | ||||
| } | } | ||||
| @@ -23,6 +23,7 @@ namespace Discord.Rest | |||||
| { | { | ||||
| switch (model.Type) | switch (model.Type) | ||||
| { | { | ||||
| case ChannelType.News: | |||||
| case ChannelType.Text: | case ChannelType.Text: | ||||
| case ChannelType.Voice: | case ChannelType.Voice: | ||||
| return RestGuildChannel.Create(discord, new RestGuild(discord, model.GuildId.Value), model); | return RestGuildChannel.Create(discord, new RestGuild(discord, model.GuildId.Value), model); | ||||
| @@ -34,6 +34,9 @@ namespace Discord.Rest | |||||
| { | { | ||||
| switch (model.Type) | switch (model.Type) | ||||
| { | { | ||||
| case ChannelType.News: | |||||
| // TODO: create new RestNewsChannel | |||||
| throw new NotImplementedException(); | |||||
| case ChannelType.Text: | case ChannelType.Text: | ||||
| return RestTextChannel.Create(discord, guild, model); | return RestTextChannel.Create(discord, guild, model); | ||||
| case ChannelType.Voice: | case ChannelType.Voice: | ||||
| @@ -48,6 +48,9 @@ namespace Discord.WebSocket | |||||
| { | { | ||||
| switch (model.Type) | switch (model.Type) | ||||
| { | { | ||||
| case ChannelType.News: | |||||
| // TODO: create new SocketNewsChannel | |||||
| throw new NotImplementedException(); | |||||
| case ChannelType.Text: | case ChannelType.Text: | ||||
| return SocketTextChannel.Create(guild, state, model); | return SocketTextChannel.Create(guild, state, model); | ||||
| case ChannelType.Voice: | case ChannelType.Voice: | ||||