mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 03:25:12 +01:00
fix data not being passed on, caused crash on initial sync
This commit is contained in:
parent
a11b612640
commit
75bff228ec
@ -181,7 +181,7 @@ export class Room extends EventEmitter {
|
||||
// fetch new members while we have txn open,
|
||||
// but don't make any in-memory changes yet
|
||||
let heroChanges;
|
||||
if (needsHeroes(summaryChanges)) {
|
||||
if (summaryChanges && needsHeroes(summaryChanges)) {
|
||||
// room name disappeared, open heroes
|
||||
if (!this._heroes) {
|
||||
this._heroes = new Heroes(this._roomId);
|
||||
|
@ -52,6 +52,7 @@ function applySyncResponse(data, roomResponse, membership) {
|
||||
if (typeof event.state_key === "string") {
|
||||
return processStateEvent(data, event);
|
||||
}
|
||||
return data;
|
||||
}, data);
|
||||
}
|
||||
const unreadNotifications = roomResponse.unread_notifications;
|
||||
@ -309,7 +310,7 @@ export class RoomSummary {
|
||||
this._data.cloned = false;
|
||||
let data = applySyncResponse(this._data, roomResponse, membership);
|
||||
data = applyTimelineEntries(
|
||||
this._data,
|
||||
data,
|
||||
timelineEntries,
|
||||
isInitialSync, isTimelineOpen,
|
||||
this._ownUserId);
|
||||
|
Loading…
Reference in New Issue
Block a user