소스 검색

mol-state: fix root node update

David Sehnal 6 년 전
부모
커밋
ea635a6979
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  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;