Migrated block, unblock and get user block list methods to Helix (#2370)

Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
Paweł
2021-02-14 14:01:13 +01:00
committed by GitHub
parent 46f1347e4b
commit 7d9f4c2b0c
14 changed files with 406 additions and 349 deletions
@@ -138,18 +138,17 @@ bool TwitchMessageBuilder::isIgnored() const
auto app = getApp();
if (getSettings()->enableTwitchIgnoredUsers &&
if (getSettings()->enableTwitchBlockedUsers &&
this->tags.contains("user-id"))
{
auto sourceUserID = this->tags.value("user-id").toString();
for (const auto &user :
app->accounts->twitch.getCurrent()->getIgnores())
for (const auto &user : app->accounts->twitch.getCurrent()->getBlocks())
{
if (sourceUserID == user.id)
{
switch (static_cast<ShowIgnoredUsersMessages>(
getSettings()->showIgnoredUsersMessages.getValue()))
getSettings()->showBlockedUsersMessages.getValue()))
{
case ShowIgnoredUsersMessages::IfModerator:
if (this->channel->isMod() ||