mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
Slightly changed ConsoleOutputDisableExpressionTemplate
This commit is contained in:
+3
-3
@@ -9,9 +9,9 @@ export function ConsoleOutputDisableExpressionTemplate (): string {
|
||||
const _console = (that.console = that.console || {});
|
||||
const methods = ['log', 'warn', 'info', 'error', 'exception', 'table', 'trace'];
|
||||
|
||||
for (var i = 0; i < methods.length; i++){
|
||||
const func = {consoleLogDisableFunctionName}.constructor();
|
||||
const methodName = methods[i];
|
||||
for (let index = 0; index < methods.length; index++){
|
||||
const func = {callControllerFunctionName}.constructor();
|
||||
const methodName = methods[index];
|
||||
const originalFunction = _console[methodName] || func;
|
||||
|
||||
func.toString = originalFunction.toString.bind(originalFunction);
|
||||
|
||||
Reference in New Issue
Block a user