Improve network error messages (#4704)
This commit is contained in:
@@ -273,24 +273,17 @@ void FfzEmotes::loadChannel(
|
||||
makeSystemMessage(CHANNEL_HAS_NO_EMOTES));
|
||||
}
|
||||
}
|
||||
else if (result.status() == NetworkResult::timedoutStatus)
|
||||
{
|
||||
// TODO: Auto retry in case of a timeout, with a delay
|
||||
qCWarning(chatterinoFfzemotes)
|
||||
<< "Fetching FFZ emotes for channel" << channelID
|
||||
<< "failed due to timeout";
|
||||
shared->addMessage(
|
||||
makeSystemMessage("Failed to fetch FrankerFaceZ channel "
|
||||
"emotes. (timed out)"));
|
||||
}
|
||||
else
|
||||
{
|
||||
// TODO: Auto retry in case of a timeout, with a delay
|
||||
auto errorString = result.formatError();
|
||||
qCWarning(chatterinoFfzemotes)
|
||||
<< "Error fetching FFZ emotes for channel" << channelID
|
||||
<< ", error" << result.status();
|
||||
shared->addMessage(
|
||||
makeSystemMessage("Failed to fetch FrankerFaceZ channel "
|
||||
"emotes. (unknown error)"));
|
||||
<< ", error" << errorString;
|
||||
shared->addMessage(makeSystemMessage(
|
||||
QStringLiteral("Failed to fetch FrankerFaceZ channel "
|
||||
"emotes. (Error: %1)")
|
||||
.arg(errorString)));
|
||||
}
|
||||
})
|
||||
.execute();
|
||||
|
||||
Reference in New Issue
Block a user