mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
deps update, finally moved on latest @type/node
This commit is contained in:
Vendored
+11
-11
@@ -135,7 +135,7 @@ var Utils = function () {
|
||||
}, {
|
||||
key: 'btoa',
|
||||
value: function btoa(string) {
|
||||
var encode = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1];
|
||||
var encode = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
||||
|
||||
return new Buffer(encode ? encodeURI(string) : string).toString('base64');
|
||||
}
|
||||
@@ -165,7 +165,7 @@ var Utils = function () {
|
||||
}, {
|
||||
key: 'getRandomVariableName',
|
||||
value: function getRandomVariableName() {
|
||||
var length = arguments.length <= 0 || arguments[0] === undefined ? 6 : arguments[0];
|
||||
var length = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 6;
|
||||
|
||||
var rangeMinInteger = 10000,
|
||||
rangeMaxInteger = 99999999,
|
||||
@@ -299,7 +299,7 @@ var NodeUtils = function () {
|
||||
}, {
|
||||
key: 'getBlockStatementNodeByIndex',
|
||||
value: function getBlockStatementNodeByIndex(node) {
|
||||
var index = arguments.length <= 1 || arguments[1] === undefined ? 0 : arguments[1];
|
||||
var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
||||
|
||||
if (Nodes_1.Nodes.isNodeHasBlockStatement(node)) {
|
||||
if (node.body[index] === undefined) {
|
||||
@@ -312,7 +312,7 @@ var NodeUtils = function () {
|
||||
}, {
|
||||
key: 'getBlockScopeOfNode',
|
||||
value: function getBlockScopeOfNode(node) {
|
||||
var depth = arguments.length <= 1 || arguments[1] === undefined ? 0 : arguments[1];
|
||||
var depth = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
||||
|
||||
var parentNode = node.parentNode;
|
||||
if (!parentNode) {
|
||||
@@ -381,7 +381,7 @@ var NodeUtils = function () {
|
||||
}, {
|
||||
key: 'typedTraverse',
|
||||
value: function typedTraverse(node, nodeType, visitor) {
|
||||
var traverseType = arguments.length <= 3 || arguments[3] === undefined ? 'traverse' : arguments[3];
|
||||
var traverseType = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'traverse';
|
||||
|
||||
estraverse[traverseType](node, {
|
||||
enter: function enter(node, parentNode) {
|
||||
@@ -657,7 +657,7 @@ var JavaScriptObfuscator = function () {
|
||||
_createClass(JavaScriptObfuscator, null, [{
|
||||
key: "obfuscate",
|
||||
value: function obfuscate(sourceCode) {
|
||||
var obfuscatorOptions = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1];
|
||||
var obfuscatorOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
||||
|
||||
var javaScriptObfuscator = new JavaScriptObfuscatorInternal_1.JavaScriptObfuscatorInternal(sourceCode, obfuscatorOptions);
|
||||
javaScriptObfuscator.obfuscate();
|
||||
@@ -1118,7 +1118,7 @@ var SourceMapCorrector_1 = __webpack_require__(26);
|
||||
|
||||
var JavaScriptObfuscatorInternal = function () {
|
||||
function JavaScriptObfuscatorInternal(sourceCode) {
|
||||
var obfuscatorOptions = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1];
|
||||
var obfuscatorOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
||||
|
||||
_classCallCheck(this, JavaScriptObfuscatorInternal);
|
||||
|
||||
@@ -1417,7 +1417,7 @@ var CLIUtils = function () {
|
||||
}, {
|
||||
key: 'getOutputSourceMapPath',
|
||||
value: function getOutputSourceMapPath(outputCodePath) {
|
||||
var sourceMapFileName = arguments.length <= 1 || arguments[1] === undefined ? '' : arguments[1];
|
||||
var sourceMapFileName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
||||
|
||||
if (sourceMapFileName) {
|
||||
outputCodePath = outputCodePath.substr(0, outputCodePath.lastIndexOf('/')) + '/' + sourceMapFileName;
|
||||
@@ -2133,7 +2133,7 @@ var UnicodeArrayNode = function (_AbstractCustomNode_) {
|
||||
_inherits(UnicodeArrayNode, _AbstractCustomNode_);
|
||||
|
||||
function UnicodeArrayNode(unicodeArray, unicodeArrayName) {
|
||||
var unicodeArrayRotateValue = arguments.length <= 2 || arguments[2] === undefined ? 0 : arguments[2];
|
||||
var unicodeArrayRotateValue = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
||||
var options = arguments[3];
|
||||
|
||||
_classCallCheck(this, UnicodeArrayNode);
|
||||
@@ -3177,11 +3177,11 @@ __decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)],
|
||||
__decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)], Options.prototype, "debugProtection", void 0);
|
||||
__decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)], Options.prototype, "debugProtectionInterval", void 0);
|
||||
__decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)], Options.prototype, "disableConsoleOutput", void 0);
|
||||
__decorate([class_validator_1.ArrayUnique(), class_validator_1.IsString({
|
||||
__decorate([class_validator_1.IsArray(), class_validator_1.ArrayUnique(), class_validator_1.IsString({
|
||||
each: true
|
||||
}), __metadata('design:type', Array)], Options.prototype, "domainLock", void 0);
|
||||
__decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)], Options.prototype, "encodeUnicodeLiterals", void 0);
|
||||
__decorate([class_validator_1.ArrayUnique(), class_validator_1.IsString({
|
||||
__decorate([class_validator_1.IsArray(), class_validator_1.ArrayUnique(), class_validator_1.IsString({
|
||||
each: true
|
||||
}), __metadata('design:type', Array)], Options.prototype, "reservedNames", void 0);
|
||||
__decorate([class_validator_1.IsBoolean(), __metadata('design:type', Boolean)], Options.prototype, "rotateUnicodeArray", void 0);
|
||||
|
||||
+14
-14
@@ -29,29 +29,29 @@
|
||||
"estraverse": "^4.2.0",
|
||||
"format-unicorn": "^1.1.0",
|
||||
"mkdirp": "^0.5.1",
|
||||
"source-map-support": "^0.4.2"
|
||||
"source-map-support": "^0.4.3"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/chai": "^3.4.32",
|
||||
"@types/chance": "^0.7.28",
|
||||
"@types/commander": "^2.3.29",
|
||||
"@types/chai": "^3.4.34",
|
||||
"@types/chance": "^0.7.30",
|
||||
"@types/commander": "^2.3.30",
|
||||
"@types/escodegen": "^0.0.6",
|
||||
"@types/esprima": "^2.1.31",
|
||||
"@types/esprima": "^2.1.33",
|
||||
"@types/estraverse": "^0.0.6",
|
||||
"@types/estree": "^0.0.32",
|
||||
"@types/format-unicorn": "^0.0.28",
|
||||
"@types/joi": "^9.0.31",
|
||||
"@types/mkdirp": "^0.3.28",
|
||||
"@types/mocha": "^2.2.31",
|
||||
"@types/node": "^4.0.30",
|
||||
"@types/sinon": "^1.16.29",
|
||||
"babel-cli": "^6.14.0",
|
||||
"@types/format-unicorn": "^0.0.29",
|
||||
"@types/joi": "^9.0.32",
|
||||
"@types/mkdirp": "^0.3.29",
|
||||
"@types/mocha": "^2.2.32",
|
||||
"@types/node": "^6.0.41",
|
||||
"@types/sinon": "^1.16.31",
|
||||
"babel-cli": "^6.16.0",
|
||||
"babel-loader": "^6.2.5",
|
||||
"babel-preset-es2015": "^6.14.0",
|
||||
"babel-preset-es2015": "^6.16.0",
|
||||
"chai": "^3.5.0",
|
||||
"coveralls": "^2.11.14",
|
||||
"istanbul": "1.1.0-alpha.1",
|
||||
"mocha": "^3.0.2",
|
||||
"mocha": "^3.1.0",
|
||||
"optimize-js-plugin": "0.0.4",
|
||||
"sinon": "^2.0.0-pre.3",
|
||||
"ts-loader": "^0.8.2",
|
||||
|
||||
Reference in New Issue
Block a user