Skip to content

Commit

Permalink
feat: Zoe remember the new bundleId when upgrading a contract
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris-Hibbert committed Feb 24, 2024
1 parent fc2d0f0 commit 5a30b2d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vats/src/proposals/probeZcfBundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export const probeZcfBundleCap = async (
await E(adminNode).upgrade(zoeBundleCap, {});

// STEP 4: restart WF ////////////////////////
await E(walletAdminFacet).upgradeContract(walletRef.bundleID, privateArgs);
await E(walletAdminFacet).restartContract(privateArgs);

// ////// See which zcf bundle was used //////////
};
Expand Down
1 change: 1 addition & 0 deletions packages/zoe/src/zoeService/startInstance.js
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,7 @@ export const makeStartInstance = (
contractBundleCap: newContractBundleCap,
privateArgs: newPrivateArgs,
};
state.contractBundleCap = newContractBundleCap;
return E.when(getFreshZcfBundleCap(), bCap =>
E(state.adminNode).upgrade(bCap, { vatParameters }),
);
Expand Down

0 comments on commit 5a30b2d

Please sign in to comment.