Fix crash that could occur when closing down the last of a channel when reloading emotes (#4278)
* Fix crash that could occur when a channel is closed Ensure we copy the QString in case the channel goes out of scope and we're referring to nothing * Add changelog entry
This commit is contained in:
@@ -169,8 +169,7 @@ void BttvEmotes::loadChannel(std::weak_ptr<Channel> channel,
|
||||
{
|
||||
NetworkRequest(QString(bttvChannelEmoteApiUrl) + channelId)
|
||||
.timeout(20000)
|
||||
.onSuccess([callback = std::move(callback), channel,
|
||||
&channelDisplayName,
|
||||
.onSuccess([callback = std::move(callback), channel, channelDisplayName,
|
||||
manualRefresh](auto result) -> Outcome {
|
||||
auto pair =
|
||||
parseChannelEmotes(result.parseJson(), channelDisplayName);
|
||||
|
||||
Reference in New Issue
Block a user