From be0d8aefa5e4cee6dc7b6a0f7df7219125fc53cd Mon Sep 17 00:00:00 2001 From: fengmk2 Date: Mon, 4 Apr 2016 21:06:19 +0800 Subject: [PATCH] fix: should not check sync status on `exist` mode closes #858 --- sync/index.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sync/index.js b/sync/index.js index a88996869..3612b5d86 100644 --- a/sync/index.js +++ b/sync/index.js @@ -186,8 +186,6 @@ function* checkSyncStatus() { var lastSyncTime; if (config.syncModel === 'all') { lastSyncTime = total.last_sync_time; - } else if (config.syncModel === 'exist') { - lastSyncTime = total.last_exist_sync_time; } debug('checkSyncStatus start, lastSyncTime: %s, syncInterval: %s', lastSyncTime, syncInterval); if (!lastSyncTime) { @@ -197,7 +195,7 @@ function* checkSyncStatus() { var oneDay = 3600000 * 24; if (diff > oneDay) { var err = new Error('Last sync time is expired in ' + diff + ' ms, lastSyncTime: ' + new Date(lastSyncTime)); - err.name = 'SyncExpriedError'; + err.name = 'SyncExpiredError'; sendMailToAdmin(err, null, new Date()); } }