From 759f16d5b98548f004c6c2678c45f60f7faf671b Mon Sep 17 00:00:00 2001 From: Ajay Bura <32841439+ajbura@users.noreply.github.com> Date: Wed, 28 Sep 2022 18:17:15 +0530 Subject: [PATCH] Fix crash on space leave --- src/app/organisms/navigation/Home.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/organisms/navigation/Home.jsx b/src/app/organisms/navigation/Home.jsx index 9e74956..6bfa6c0 100644 --- a/src/app/organisms/navigation/Home.jsx +++ b/src/app/organisms/navigation/Home.jsx @@ -25,7 +25,7 @@ function Home({ spaceId }) { let directIds = []; if (spaceId) { - const spaceChildIds = roomList.getSpaceChildren(spaceId); + const spaceChildIds = roomList.getSpaceChildren(spaceId) ?? []; spaceIds = spaceChildIds.filter((roomId) => spaces.has(roomId)); roomIds = spaceChildIds.filter((roomId) => rooms.has(roomId)); directIds = spaceChildIds.filter((roomId) => directs.has(roomId));