[bugfix] Return the error code, don't discard it.

This commit is contained in:
Tomaz Canabrava 2017-09-12 11:06:57 +02:00 committed by Roeland Jago Douma
parent 29b64640fa
commit f4bbec1019
No known key found for this signature in database
GPG key ID: F941078878347C0C

View file

@ -787,6 +787,7 @@ bool JsonApiJob::finished()
if (reply()->error() != QNetworkReply::NoError) {
qCWarning(lcJsonApiJob) << "Network error: " << path() << errorString() << reply()->attribute(QNetworkRequest::HttpStatusCodeAttribute);
statusCode = reply()->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
emit jsonReceived(QJsonDocument(), statusCode);
return true;
}