Skip to content

Commit

Permalink
Merge pull request #123 from landas/existing-log-error
Browse files Browse the repository at this point in the history
Fixed error when uploading existing log.
  • Loading branch information
manisandro authored Mar 23, 2017
2 parents df6db61 + b3ae85d commit b322597
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/movescount/movescount.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -340,14 +340,14 @@ void MovesCount::writeLogInThread(LogEntry *logEntry)

reply = syncPOST("/moves/", "", output, true);

if (reply->error() == QNetworkReply::NoError) {
if (reply->error() == QNetworkReply::NoError || reply->error() == QNetworkReply::UnknownContentError) {
QByteArray data = reply->readAll();
if (jsonParser.parseLogReply(data, moveId) == 0) {
emit logMoveID(logEntry->device, logEntry->time, moveId);
}
}
}
else {
qDebug() << "Failed to upload log, movescount.com replied with \"" << reply->readAll() << "\"";
qDebug() << "Failed to upload log (err code:" << reply->error() << "), movescount.com replied with \"" << reply->readAll() << "\"";
}
}

Expand Down

0 comments on commit b322597

Please sign in to comment.