diff --git a/services/sync/modules/service.js b/services/sync/modules/service.js index a8f27c4e2916..a0e84d794b6f 100644 --- a/services/sync/modules/service.js +++ b/services/sync/modules/service.js @@ -474,10 +474,14 @@ WeaveSvc.prototype = { this._log.debug("Logging in user " + this.username); - yield this.verifyLogin(self.cb, this.username, this.password); - - this._loggedIn = true; - self.done(true); + try { + yield this.verifyLogin(self.cb, this.username, this.password); + this._loggedIn = true; + self.done(true); + } catch (e) { + this._loggedIn = false; + self.done(false); + } }; this._localLock( this._catchAll(