Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
Ensure artifacts are saved with db info
Browse files Browse the repository at this point in the history
  • Loading branch information
g. nicholas d'andrea committed Nov 25, 2020
1 parent 31275ed commit 88fb88f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/workflow-compile/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,6 @@ const WorkflowCompile = {

await fse.ensureDir(config.contracts_build_directory);

const artifacts = contracts.map(Shims.NewToLegacy.forContract);
await config.artifactor.saveAll(artifacts);

if (options.db && options.db.enabled === true && contracts.length > 0) {
const db = connect(config);
const project = await Project.initialize({
Expand All @@ -126,10 +123,13 @@ const WorkflowCompile = {
directory: config.working_directory
}
});
await project.loadCompile({
({contracts} = await project.loadCompile({
result: {contracts, compilations}
});
}));
}

const artifacts = contracts.map(Shims.NewToLegacy.forContract);
await config.artifactor.saveAll(artifacts);
}
};

Expand Down

0 comments on commit 88fb88f

Please sign in to comment.