when whenNoShim runs noShim if-branch main should return immediately

This commit is contained in:
Michael Bradley, Jr 2018-10-31 18:01:44 +01:00
parent a9bf409aa0
commit f3ba725efc
1 changed files with 4 additions and 8 deletions

View File

@ -15,7 +15,7 @@
// package.json under `{"embark": {...}}` -or- stored in an embark.json file.
function main() {
whenNoShim();
if (whenNoShim()) return;
var invoked = thisEmbark();
var embarkJson = findEmbarkJson();
var dappPath = embarkJson.dirname;
@ -725,13 +725,9 @@ function thisEmbark() {
}
function whenNoShim() {
var noShim = false;
if (process.env.EMBARK_NO_SHIM) {
noShim = true;
}
if (noShim) {
EmbarkBin.prototype.exec();
}
var noShim = !!process.env.EMBARK_NO_SHIM;
if (noShim) EmbarkBin.prototype.exec();
return noShim;
}
// -- reporters ----------------------------------------------------------------