fix(@embark/pipeline): revise require in embarkArtifacts/contracts/index

This commit is contained in:
Michael Bradley, Jr 2019-08-20 14:13:21 -05:00 committed by Michael Bradley
parent 3a9fa56349
commit ff97aa5b3e
1 changed files with 1 additions and 1 deletions

View File

@ -372,7 +372,7 @@ class Pipeline {
// e.g. import * as Contracts from 'Embark/contracts' // e.g. import * as Contracts from 'Embark/contracts'
let importHelperFileCode = 'module.exports = {\n'; let importHelperFileCode = 'module.exports = {\n';
Object.values(contracts).forEach(contract => { Object.values(contracts).forEach(contract => {
importHelperFileCode += `"${contract.className}": require('./${contract.className}').default,\n`; importHelperFileCode += `"${contract.className}": require('./${contract.className}'),\n`;
}); });
importHelperFileCode += '};'; importHelperFileCode += '};';
self.fs.writeFile(joinPath(contractsDir, 'index.js'), importHelperFileCode, (err) => { self.fs.writeFile(joinPath(contractsDir, 'index.js'), importHelperFileCode, (err) => {