diff --git a/webapp/packages/core-app/src/NavigationTree/ElementsTree/useElementsTree.ts b/webapp/packages/core-app/src/NavigationTree/ElementsTree/useElementsTree.ts index ea0b0958d2..64b641383c 100644 --- a/webapp/packages/core-app/src/NavigationTree/ElementsTree/useElementsTree.ts +++ b/webapp/packages/core-app/src/NavigationTree/ElementsTree/useElementsTree.ts @@ -128,8 +128,8 @@ export function useElementsTree(options: IOptions): IElementsTree { const nextChildren: string[] = []; for (const child of children) { - await navNodeInfoResource.waitLoad(); await navTreeResource.waitLoad(); + await navNodeInfoResource.waitLoad(); const expanded = elementsTree.isNodeExpanded(child, true); if (!expanded && child !== options.root) { diff --git a/webapp/packages/core-app/src/shared/NodesManager/NavNodeInfoResource.ts b/webapp/packages/core-app/src/shared/NodesManager/NavNodeInfoResource.ts index 0c0510d6f7..e1c4c5bdd8 100644 --- a/webapp/packages/core-app/src/shared/NodesManager/NavNodeInfoResource.ts +++ b/webapp/packages/core-app/src/shared/NodesManager/NavNodeInfoResource.ts @@ -40,6 +40,8 @@ export class NavNodeInfoResource extends CachedMapResource { makeObservable(this, { setDetails: action, + updateNode: action, + setParent: action, }); this.metadata = new MetadataMap(() => ({ @@ -72,10 +74,9 @@ export class NavNodeInfoResource extends CachedMapResource { if (keyList.length > 0) { this.set(resourceKeyList(keyList), values); - } else { - this.markUpdated(key); - this.onItemAdd.execute(key); } + this.markUpdated(key); + this.onItemAdd.execute(key); } setDetails(keyObject: ResourceKey, state: boolean): void {