From 4f1a0ad5a6c5b678ecfbc3a8c6ec6b646e569e8a Mon Sep 17 00:00:00 2001 From: nerix Date: Wed, 1 Jan 2025 12:22:45 +0100 Subject: [PATCH] fix(bttv): use `channel` if no user was sent (#5783) --- CHANGELOG.md | 1 + src/providers/bttv/BttvEmotes.cpp | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index bd67a95b..32809701 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ - Bugfix: Fixed scrollbar highlights being visible in overlay windows. (#5769) - Bugfix: Make macos fonts look the same as v2.5.1. (#5775) - Bugfix: Fixed 7TV usernames messing with Qt's HTML (#5780) +- Bugfix: Fixed BTTV emotes occasionally showing the wrong author. (#5783) - Dev: Hard-code Boost 1.86.0 in macos CI builders. (#5774) ## 2.5.2-beta.1 diff --git a/src/providers/bttv/BttvEmotes.cpp b/src/providers/bttv/BttvEmotes.cpp index 60bd07b3..f6f302e3 100644 --- a/src/providers/bttv/BttvEmotes.cpp +++ b/src/providers/bttv/BttvEmotes.cpp @@ -92,6 +92,10 @@ CreateEmoteResult createChannelEmote(const QString &channelDisplayName, auto name = EmoteName{jsonEmote.value("code").toString()}; auto author = EmoteAuthor{ jsonEmote.value("user").toObject().value("displayName").toString()}; + if (author.string.isEmpty()) + { + author.string = jsonEmote["channel"].toString(); + } auto emote = Emote({ name,