implementation of forcing full (re)sync

This commit is contained in:
azivner
2017-12-13 23:03:48 -05:00
parent e6686c4b32
commit b0cbe91784
8 changed files with 56 additions and 38 deletions

View File

@@ -1,7 +1,6 @@
const sql = require('./sql');
const log = require('./log');
const options = require('./options');
const utils = require('./utils');
const eventLog = require('./event_log');
const notes = require('./notes');
const sync_table = require('./sync_table');
@@ -19,9 +18,6 @@ async function updateNote(entity, sourceId) {
log.info("Update/sync note " + entity.note_id);
}
else {
await eventLog.addNoteEvent(entity.note_id, "Sync conflict in note <note>, " + utils.formatTwoDates(origNote.date_modified, entity.date_modified));
}
}
async function updateNoteTree(entity, sourceId) {
@@ -37,9 +33,6 @@ async function updateNoteTree(entity, sourceId) {
log.info("Update/sync note tree " + entity.note_tree_id);
}
else {
await eventLog.addNoteEvent(entity.note_tree_id, "Sync conflict in note tree <note>, " + utils.formatTwoDates(orig.date_modified, entity.date_modified));
}
});
}
@@ -54,9 +47,6 @@ async function updateNoteHistory(entity, sourceId) {
log.info("Update/sync note history " + entity.note_history_id);
}
else {
await eventLog.addNoteEvent(entity.note_id, "Sync conflict in note history for <note>, " + utils.formatTwoDates(orig.date_modified_to, entity.date_modified_to));
}
});
}
@@ -85,9 +75,6 @@ async function updateOptions(entity, sourceId) {
await eventLog.addEvent("Synced option " + entity.opt_name);
}
else {
await eventLog.addEvent("Sync conflict in options for " + entity.opt_name + ", " + utils.formatTwoDates(orig.date_modified, entity.date_modified));
}
});
}