correctly wait for catchup sync
This commit is contained in:
parent
225fe873be
commit
1fa14a99e9
2 changed files with 2 additions and 2 deletions
|
@ -25,7 +25,7 @@ export class SessionLoadViewModel extends ViewModel {
|
|||
this.emitChange();
|
||||
// wait for initial sync, but not catchup sync
|
||||
const isCatchupSync = s === LoadStatus.FirstSync &&
|
||||
this._sessionContainer.sync.status === SyncStatus.CatchupSync;
|
||||
this._sessionContainer.sync.status.get() === SyncStatus.CatchupSync;
|
||||
return isCatchupSync ||
|
||||
s === LoadStatus.LoginFailed ||
|
||||
s === LoadStatus.Error ||
|
||||
|
|
|
@ -159,8 +159,8 @@ export class SessionContainer {
|
|||
|
||||
async _waitForFirstSync() {
|
||||
try {
|
||||
this._status.set(LoadStatus.FirstSync);
|
||||
this._sync.start();
|
||||
this._status.set(LoadStatus.FirstSync);
|
||||
} catch (err) {
|
||||
// swallow ConnectionError here and continue,
|
||||
// as the reconnector above will call
|
||||
|
|
Reference in a new issue