mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2025-01-22 10:11:39 +01:00
correctly wait for catchup sync
This commit is contained in:
parent
225fe873be
commit
1fa14a99e9
@ -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
|
||||
|
Loading…
x
Reference in New Issue
Block a user