mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-11-04 22:40:29 +03:00
improve function naming
This commit is contained in:
parent
b4d7f520c5
commit
df8ba32725
1 changed files with 3 additions and 3 deletions
|
|
@ -204,7 +204,7 @@ const getSpaceJoinedHierarchy = (
|
||||||
* @param spaceId - The space ID to check.
|
* @param spaceId - The space ID to check.
|
||||||
* @returns True if the space or any descendant contains non-space rooms.
|
* @returns True if the space or any descendant contains non-space rooms.
|
||||||
*/
|
*/
|
||||||
const containsRoom = (spaceId: string) => {
|
const getContainsRoom = (spaceId: string) => {
|
||||||
const space = getRoom(spaceId);
|
const space = getRoom(spaceId);
|
||||||
if (!space) return false;
|
if (!space) return false;
|
||||||
|
|
||||||
|
|
@ -217,7 +217,7 @@ const getSpaceJoinedHierarchy = (
|
||||||
if (!room) return false;
|
if (!room) return false;
|
||||||
|
|
||||||
if (!room.isSpaceRoom()) return true;
|
if (!room.isSpaceRoom()) return true;
|
||||||
return containsRoom(childId);
|
return getContainsRoom(childId);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -236,7 +236,7 @@ const getSpaceJoinedHierarchy = (
|
||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!containsRoom(spaceItem.roomId)) return [];
|
if (!getContainsRoom(spaceItem.roomId)) return [];
|
||||||
|
|
||||||
const childItems: HierarchyItemRoom[] = [];
|
const childItems: HierarchyItemRoom[] = [];
|
||||||
joinedRoomEvents.forEach((childEvent) => {
|
joinedRoomEvents.forEach((childEvent) => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue