From 9e78f8382a886129bffb0c159c6a7b991a852a3b Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Thu, 6 May 2021 12:10:10 +0200 Subject: [PATCH] dont assume there is a rooms section in the sync --- src/matrix/Sync.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/matrix/Sync.js b/src/matrix/Sync.js index cf31f3c2..a99c0938 100644 --- a/src/matrix/Sync.js +++ b/src/matrix/Sync.js @@ -375,7 +375,7 @@ export class Sync { _parseInvites(roomsSection) { const inviteStates = []; - if (roomsSection.invite) { + if (roomsSection?.invite) { for (const [roomId, roomResponse] of Object.entries(roomsSection.invite)) { let invite = this._session.invites.get(roomId); let isNewInvite = false;