diff --git a/core/merginapi.cpp b/core/merginapi.cpp index adc32b13a..62f2461a2 100644 --- a/core/merginapi.cpp +++ b/core/merginapi.cpp @@ -3960,17 +3960,18 @@ bool MerginApi::isRetryableNetworkError( QNetworkReply *reply ) Q_ASSERT( reply ); QNetworkReply::NetworkError err = reply->error(); - int httpCode = reply->attribute( QNetworkRequest::HttpStatusCodeAttribute ).toInt(); bool isRetryableError = ( err == QNetworkReply::TimeoutError || err == QNetworkReply::TemporaryNetworkFailureError || err == QNetworkReply::NetworkSessionFailedError || - err == QNetworkReply::UnknownNetworkError ); - - bool isRetryableHttpCode = ( httpCode == 500 || httpCode == 502 || - httpCode == 503 || httpCode == 504 ); - - return isRetryableError || isRetryableHttpCode; + err == QNetworkReply::UnknownNetworkError || + err == QNetworkReply::RemoteHostClosedError || + err == QNetworkReply::ProxyConnectionClosedError || + err == QNetworkReply::ProxyTimeoutError || + err == QNetworkReply::UnknownProxyError || + err == QNetworkReply::ServiceUnavailableError ); + + return isRetryableError; } void MerginApi::setNetworkManager( QNetworkAccessManager *manager )