summaryrefslogtreecommitdiff
path: root/discord
diff options
context:
space:
mode:
Diffstat (limited to 'discord')
-rw-r--r--discord/guild.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/discord/guild.cpp b/discord/guild.cpp
index eaaedc8..94268d8 100644
--- a/discord/guild.cpp
+++ b/discord/guild.cpp
@@ -134,9 +134,9 @@ std::vector<Snowflake> Guild::GetSortedChannels(Snowflake ignore) const {
for (const auto &channel_id : channels) {
const auto *data = discord.GetChannel(channel_id);
if (data == nullptr) continue;
- if (!data->ParentID.IsValid() && data->Type == ChannelType::GUILD_TEXT)
+ if (!data->ParentID.IsValid() && (data->Type == ChannelType::GUILD_TEXT || data->Type == ChannelType::GUILD_NEWS))
orphan_channels[data->Position].push_back(data);
- else if (data->ParentID.IsValid() && data->Type == ChannelType::GUILD_TEXT)
+ else if (data->ParentID.IsValid() && (data->Type == ChannelType::GUILD_TEXT || data->Type == ChannelType::GUILD_NEWS))
category_to_channels[data->ParentID].push_back(data);
else if (data->Type == ChannelType::GUILD_CATEGORY)
position_to_categories[data->Position].push_back(data);