refactor: load Twitch emotes from Helix (#5239)

This commit is contained in:
nerix
2024-09-01 11:22:54 +02:00
committed by GitHub
parent 03b0e4881f
commit 820aa12af6
40 changed files with 1251 additions and 528 deletions
+9 -1
View File
@@ -1,7 +1,7 @@
#include "providers/twitch/TwitchUser.hpp"
#include "debug/AssertInGuiThread.hpp"
#include "providers/twitch/api/Helix.hpp"
#include "util/RapidjsonHelpers.hpp"
namespace chatterino {
@@ -12,4 +12,12 @@ void TwitchUser::fromHelixBlock(const HelixBlock &ignore)
this->displayName = ignore.displayName;
}
void TwitchUser::update(const HelixUser &user) const
{
assertInGuiThread();
assert(this->id == user.id);
this->name = user.login;
this->displayName = user.displayName;
}
} // namespace chatterino