From d57057ba28d2d93ffaeed15900116836fc791968 Mon Sep 17 00:00:00 2001 From: azivner Date: Sat, 14 Apr 2018 08:23:06 -0400 Subject: [PATCH] fix note ordering sync --- src/services/sync.js | 2 +- src/services/sync_update.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/services/sync.js b/src/services/sync.js index 12669caeb..33a26602a 100644 --- a/src/services/sync.js +++ b/src/services/sync.js @@ -101,7 +101,7 @@ async function pullSync(syncContext) { log.info(`Skipping pull #${sync.id} ${sync.entityName} ${sync.entityId} because ${sync.sourceId} is a local source id.`); } else { - await syncUpdateService.updateEntity(sync.entityName, entity, syncContext.sourceId); + await syncUpdateService.updateEntity(sync, entity, syncContext.sourceId); } await setLastSyncedPull(sync.id); diff --git a/src/services/sync_update.js b/src/services/sync_update.js index 6fc7632bf..d7b2dd70a 100644 --- a/src/services/sync_update.js +++ b/src/services/sync_update.js @@ -37,7 +37,7 @@ async function updateEntity(sync, entity, sourceId) { await updateApiToken(entity, sourceId); } else { - throw new Error(`Unrecognized entity type ${entityName}`); + throw new Error(`Unrecognized entity type ${sync}`); } }