diff options
author | ouwou <26526779+ouwou@users.noreply.github.com> | 2021-12-01 03:42:15 -0500 |
---|---|---|
committer | ouwou <26526779+ouwou@users.noreply.github.com> | 2021-12-01 03:42:15 -0500 |
commit | 8e11dd97e9effa0b4abf9945ad3ec3fee9d9ec5d (patch) | |
tree | 6fb6764ea4aa90c0700c6c046a5c6cd0af82866f /src/discord/channel.cpp | |
parent | 2690febf20aecbe3ddc52d9574b9f19c8b93171c (diff) | |
download | abaddon-portaudio-8e11dd97e9effa0b4abf9945ad3ec3fee9d9ec5d.tar.gz abaddon-portaudio-8e11dd97e9effa0b4abf9945ad3ec3fee9d9ec5d.zip |
dont make requests for inaccessible channels
Diffstat (limited to 'src/discord/channel.cpp')
-rw-r--r-- | src/discord/channel.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/discord/channel.cpp b/src/discord/channel.cpp index 80b1760..d2828eb 100644 --- a/src/discord/channel.cpp +++ b/src/discord/channel.cpp @@ -63,6 +63,11 @@ bool ChannelData::NSFW() const { return IsNSFW.has_value() && *IsNSFW; } +bool ChannelData::IsDM() const noexcept { + return Type == ChannelType::DM || + Type == ChannelType::GROUP_DM; +} + bool ChannelData::IsThread() const noexcept { return Type == ChannelType::GUILD_PUBLIC_THREAD || Type == ChannelType::GUILD_PRIVATE_THREAD || |