diff --git a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts index cacd7fb7d..a371e5cb5 100644 --- a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts +++ b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts @@ -319,10 +319,7 @@ export function useUiEditorPage( const isNodePreviewVisible = useCallback( (nodeId: NodeId, treeId = activeImageId) => - !Object.prototype.hasOwnProperty.call( - treeId ? hiddenNodeIdsByImage[treeId] : undefined, - nodeId, - ), + !(treeId ? hiddenNodeIdsByImage[treeId]?.[nodeId] : false), [activeImageId, hiddenNodeIdsByImage], );