You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-15 23:00:36 +02:00
All: Fixes #600: Improved resuming of long sync operations so that it doesn't needlessly re-download the items from the beginning
This commit is contained in:
@ -570,6 +570,15 @@ class Synchronizer {
|
||||
// items being synced twice as an update. If the local and remote items are identical
|
||||
// the update will simply be skipped.
|
||||
if (!hasCancelled) {
|
||||
if (options.saveContextHandler) {
|
||||
const deltaToSave = Object.assign({}, listResult.context);
|
||||
// Remove these two variables because they can be large and can be rebuilt
|
||||
// the next time the sync is started.
|
||||
delete deltaToSave.statsCache;
|
||||
delete deltaToSave.statIdsCache;
|
||||
options.saveContextHandler({ delta: deltaToSave });
|
||||
}
|
||||
|
||||
if (!listResult.hasMore) {
|
||||
newDeltaContext = listResult.context;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user