Skip to content

Commit

Permalink
Merge pull request #223 from boo-yee/develop
Browse files Browse the repository at this point in the history
Comment out the tedious resource synchronization code.
  • Loading branch information
robert7 authored May 7, 2024
2 parents e7ed12b + a7c4ee4 commit 4e62724
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
38 changes: 19 additions & 19 deletions src/communication/communicationmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1037,25 +1037,25 @@ void CommunicationManager::processSyncChunk(SyncChunk &chunk, QString token) {
if (chunk.notes.isSet())
chunk.notes = notes;

QList<Resource> resourceData;
QLOG_DEBUG() << "All notes retrieved. Getting resources";
QList<Resource> resources;
if (chunk.resources.isSet())
resources = chunk.resources;
for (int i = 0; i < resources.size(); i++) {
QLOG_TRACE() << "Fetching chunk resource item: " << i << ": " << resources[i].guid;
Resource r;
r = noteStore->getResource(resources[i].guid, true, true, true, true, requestContext);
QLOG_TRACE() << "Resource retrieved";
resourceData.append(r);
}
if (chunk.resources.isSet())
chunk.resources = resourceData;
QLOG_DEBUG() << "Getting ink notes";
if (resources.size() > 0) {
QLOG_TRACE() << "Checking for ink notes";
checkForInkNotes(resources, "", token);
}
// QList<Resource> resourceData;
// QLOG_DEBUG() << "All notes retrieved. Getting resources";
// QList<Resource> resources;
// if (chunk.resources.isSet())
// resources = chunk.resources;
// for (int i = 0; i < resources.size(); i++) {
// QLOG_TRACE() << "Fetching chunk resource item: " << i << ": " << resources[i].guid;
// Resource r;
// r = noteStore->getResource(resources[i].guid, true, true, true, true, requestContext);
// QLOG_TRACE() << "Resource retrieved";
// resourceData.append(r);
// }
// if (chunk.resources.isSet())
// chunk.resources = resourceData;
// QLOG_DEBUG() << "Getting ink notes";
// if (resources.size() > 0) {
// QLOG_TRACE() << "Checking for ink notes";
// checkForInkNotes(resources, "", token);
// }
}


Expand Down
2 changes: 1 addition & 1 deletion src/threads/syncrunner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ bool SyncRunner::syncRemoteToLocal(qint32 updateCount) {

comm->loadTagGuidMap();
more = true;
chunkSize = 50;
chunkSize = 200;
updateSequenceNumber = startingSequenceNumber;
UserTable userTable(db);

Expand Down

0 comments on commit 4e62724

Please sign in to comment.