From 099e200ec5d40e01af722c99db205298336b960a Mon Sep 17 00:00:00 2001 From: Juan Tejada Date: Thu, 14 Jul 2016 13:44:43 -0700 Subject: [PATCH] Only log sync errors if they are permanent errors --- packages/nylas-sync/sync-worker.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/nylas-sync/sync-worker.js b/packages/nylas-sync/sync-worker.js index aeadcb213..388060445 100644 --- a/packages/nylas-sync/sync-worker.js +++ b/packages/nylas-sync/sync-worker.js @@ -197,14 +197,13 @@ class SyncWorker { } onSyncError(error) { - this._logger.error(error, `SyncWorker: Error while syncing account`) this.closeConnection() - // Continue to retry if it was a network error if (error instanceof Errors.RetryableError) { return Promise.resolve() } + this._logger.error(error, `SyncWorker: Error while syncing account`) global.Metrics.reportMetric({ name: 'sync_error', value: 1,