refactor condition to avoid checking for void 0

This commit is contained in:
Iuri Matias 2016-10-29 12:24:13 -04:00
parent 814c2bc4a4
commit bd3b05bb00
1 changed files with 1 additions and 3 deletions

View File

@ -149,9 +149,7 @@ ContractsManager.prototype.build = function(done) {
for (var j = 0; j < ref.length; j++) { for (var j = 0; j < ref.length; j++) {
var arg = ref[j]; var arg = ref[j];
if (arg[0] === "$") { if (arg[0] === "$") {
if (self.contractDependencies[className] === void 0) { self.contractDependencies[className] = self.contractDependencies[className] || [];
self.contractDependencies[className] = [];
}
self.contractDependencies[className].push(arg.substr(1)); self.contractDependencies[className].push(arg.substr(1));
} }
} }