From 1e91191fa2c599ade795e2be8537d920243c7b69 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Thu, 16 Sep 2021 14:28:55 +0100 Subject: [PATCH] Fix missing null guard in space hierarchy pagination --- src/components/structures/SpaceHierarchy.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/structures/SpaceHierarchy.tsx b/src/components/structures/SpaceHierarchy.tsx index 09099032dc..72ebf29f0b 100644 --- a/src/components/structures/SpaceHierarchy.tsx +++ b/src/components/structures/SpaceHierarchy.tsx @@ -576,7 +576,7 @@ const SpaceHierarchy = ({ const { loading, rooms, hierarchy, loadMore } = useSpaceSummary(space); const filteredRoomSet = useMemo>(() => { - if (!rooms.length) return new Set(); + if (!rooms?.length) return new Set(); const lcQuery = query.toLowerCase().trim(); if (!lcQuery) return new Set(rooms);