use for to avoid multiple callback calls

This commit is contained in:
Iuri Matias 2017-12-28 07:30:41 -05:00
parent 4976408c11
commit 1f95418504
1 changed files with 2 additions and 2 deletions

View File

@ -118,7 +118,7 @@ class DeployManager {
} }
// TODO: convert to for to avoid repeated callback // TODO: convert to for to avoid repeated callback
onDeployCode.forEach((cmd) => { for(let cmd of onDeployCode) {
self.logger.info("executing: " + cmd); self.logger.info("executing: " + cmd);
try { try {
RunCode.doEval(cmd, web3); RunCode.doEval(cmd, web3);
@ -128,7 +128,7 @@ class DeployManager {
} }
return callback(new Error(e)); return callback(new Error(e));
} }
}); }
callback(null, contractsManager); callback(null, contractsManager);
} }