From e11d42a4158ff27dceefee97a554b7e1c65fce5d Mon Sep 17 00:00:00 2001 From: Mo Bitar Date: Wed, 27 Sep 2017 11:33:56 -0500 Subject: [PATCH] Call sync observers on error --- src/lib/sync.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/lib/sync.js b/src/lib/sync.js index dc19fdd1..4a62e737 100644 --- a/src/lib/sync.js +++ b/src/lib/sync.js @@ -343,6 +343,10 @@ export default class Sync { onSyncCompletion(response); + this.syncObservers.forEach(function(mapping){ + mapping.callback(); + }) + // this.$rootScope.$broadcast("sync:error", error); this.callQueuedCallbacksAndCurrent(callback, {error: "Sync error"});