Explorar o código

mol-state: fix root node update

David Sehnal %!s(int64=6) %!d(string=hai) anos
pai
achega
ea635a6979
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/mol-state/state.ts

+ 1 - 1
src/mol-state/state.ts

@@ -276,7 +276,7 @@ namespace State {
             const current = cells.get(currentRef)!;
             const oldParams = oldTree.getValue(currentRef)!.params;
 
-            const updateKind = current.status === 'ok'
+            const updateKind = current.status === 'ok' || current.ref === ctx.tree.rootRef
                 ? await updateObject(ctx, currentRef, transform.transformer, parent, current.obj!, oldParams, transform.params)
                 : Transformer.UpdateResult.Recreate;