Merge pull request #2 from Mikt25/master
Fix for https://github.com/radswiat/webpack-auto-inject-version/issues/1
This commit is contained in:
commit
bfcd03cff9
2 changed files with 6 additions and 2 deletions
4
dist/core/utils.js
vendored
4
dist/core/utils.js
vendored
|
@ -2,7 +2,9 @@ var Utils = (function () {
|
|||
function Utils() {
|
||||
}
|
||||
Utils.isArgv = function (arg) {
|
||||
return process.argv.indexOf("--" + arg) >= 0 ? true : false;
|
||||
return Boolean(process.argv.find(function (item) {
|
||||
return item.substr(0, 2) === '--' && item.indexOf(arg) > -1;
|
||||
}));
|
||||
};
|
||||
Utils.merge = function (obj1, obj2) {
|
||||
var obj3 = {};
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
class Utils{
|
||||
|
||||
static isArgv(arg) {
|
||||
return process.argv.indexOf(`--${arg}`) >= 0 ? true : false;
|
||||
return Boolean(process.argv.find(function(item) {
|
||||
return item.substr(0, 2) === '--' && item.indexOf(arg) > -1;
|
||||
}));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue