Skip to content

Commit

Permalink
fix: ensure all presences are resolved before creating bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfig committed Jul 27, 2020
1 parent fd7a8ca commit c66e58c
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions packages/cosmic-swingset/lib/ag-solo/vats/bootstrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,21 @@ export function buildRootObject(vatPowers) {
// Make services that are provided on the real or virtual chain side
async function makeChainBundler(vats, timerDevice, vatAdminSvc) {
// Create singleton instances.
const sharingService = await E(vats.sharing).getSharingService();
const registry = await E(vats.registrar).getSharedRegistrar();
const board = await E(vats.board).getBoard();
const chainTimerService = await E(vats.timer).createTimerService(
timerDevice,
);

const zoe = E(vats.zoe).buildZoe(vatAdminSvc);
const contractHost = await E(vats.host).makeHost();
const [
sharingService,
registry,
board,
chainTimerService,
zoe,
contractHost,
] = await Promise.all([
E(vats.sharing).getSharingService(),
E(vats.registrar).getSharedRegistrar(),
E(vats.board).getBoard(),
E(vats.timer).createTimerService(timerDevice),
E(vats.zoe).buildZoe(vatAdminSvc),
E(vats.host).makeHost(),
]);

// Make the other demo mints
const issuerNames = ['moola', 'simolean'];
Expand Down

0 comments on commit c66e58c

Please sign in to comment.