Skip to content

Commit e73b1b8

Browse files
committed
Log error where it occurs and fix field name
1 parent 815df8b commit e73b1b8

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

src/libsync/discovery.cpp

+10-5
Original file line numberDiff line numberDiff line change
@@ -397,18 +397,23 @@ void ProcessDirectoryJob::processFileAnalyzeRemoteInfo(
397397
// Check for missing server data
398398
{
399399
QStringList missingData;
400-
if (serverEntry.size == -1)
400+
if (serverEntry.size == -1) {
401401
missingData.append(tr("size"));
402-
if (serverEntry.remotePerm.isNull())
402+
}
403+
if (serverEntry.remotePerm.isNull()) {
403404
missingData.append(tr("permissions"));
404-
if (serverEntry.etag.isEmpty())
405+
}
406+
if (serverEntry.etag.isEmpty()) {
405407
missingData.append(tr("etag"));
406-
if (serverEntry.fileId.isEmpty())
407-
missingData.append(tr("file id"));
408+
}
409+
if (serverEntry.fileId.isEmpty()) {
410+
missingData.append(tr("id"));
411+
}
408412
if (!missingData.isEmpty()) {
409413
item->setInstruction(CSYNC_INSTRUCTION_ERROR);
410414
_childIgnored = true;
411415
item->_errorString = tr("server reported no %1").arg(missingData.join(QLatin1String(", ")));
416+
qCWarning(lcDisco) << item->_errorString;
412417
Q_EMIT _discoveryData->itemDiscovered(item);
413418
return;
414419
}

0 commit comments

Comments
 (0)