diff --git a/src/util/networkrequest.hpp b/src/util/networkrequest.hpp index f1de1066d..07da68f4a 100644 --- a/src/util/networkrequest.hpp +++ b/src/util/networkrequest.hpp @@ -372,7 +372,9 @@ private: QObject::connect(worker, &NetworkWorker::doneUrl, this->data.caller, [data = this->data](auto reply) mutable { if (reply->error() != QNetworkReply::NetworkError::NoError) { - data.onError(reply->error()); + if (data.onError) { + data.onError(reply->error()); + } return; }