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);