mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
Renamed custom code helpers group method names
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+1
-1
File diff suppressed because one or more lines are too long
@@ -58,7 +58,7 @@ export class ConsoleOutputCodeHelperGroup extends AbstractCustomCodeHelperGroup
|
|||||||
* @param {TNodeWithStatements} nodeWithStatements
|
* @param {TNodeWithStatements} nodeWithStatements
|
||||||
* @param {ICallsGraphData[]} callsGraphData
|
* @param {ICallsGraphData[]} callsGraphData
|
||||||
*/
|
*/
|
||||||
public appendOnPreparing (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
public appendOnPreparingStage (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
||||||
if (!this.options.disableConsoleOutput) {
|
if (!this.options.disableConsoleOutput) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ export class DebugProtectionCodeHelperGroup extends AbstractCustomCodeHelperGrou
|
|||||||
* @param {TNodeWithStatements} nodeWithStatements
|
* @param {TNodeWithStatements} nodeWithStatements
|
||||||
* @param {ICallsGraphData[]} callsGraphData
|
* @param {ICallsGraphData[]} callsGraphData
|
||||||
*/
|
*/
|
||||||
public appendOnPreparing (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
public appendOnPreparingStage (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
||||||
if (!this.options.debugProtection) {
|
if (!this.options.debugProtection) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ export class DomainLockCustomCodeHelperGroup extends AbstractCustomCodeHelperGro
|
|||||||
* @param {TNodeWithStatements} nodeWithStatements
|
* @param {TNodeWithStatements} nodeWithStatements
|
||||||
* @param {ICallsGraphData[]} callsGraphData
|
* @param {ICallsGraphData[]} callsGraphData
|
||||||
*/
|
*/
|
||||||
public appendOnPreparing (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
public appendOnPreparingStage (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
||||||
if (!this.options.domainLock.length) {
|
if (!this.options.domainLock.length) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ export class SelfDefendingCodeHelperGroup extends AbstractCustomCodeHelperGroup
|
|||||||
* @param {TNodeWithStatements} nodeWithStatements
|
* @param {TNodeWithStatements} nodeWithStatements
|
||||||
* @param {ICallsGraphData[]} callsGraphData
|
* @param {ICallsGraphData[]} callsGraphData
|
||||||
*/
|
*/
|
||||||
public appendOnPreparing (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
public appendOnPreparingStage (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
||||||
if (!this.options.selfDefending) {
|
if (!this.options.selfDefending) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ export class StringArrayCodeHelperGroup extends AbstractCustomCodeHelperGroup {
|
|||||||
* @param {TNodeWithStatements} nodeWithStatements
|
* @param {TNodeWithStatements} nodeWithStatements
|
||||||
* @param {ICallsGraphData[]} callsGraphData
|
* @param {ICallsGraphData[]} callsGraphData
|
||||||
*/
|
*/
|
||||||
public appendOnFinalizing (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
public appendOnFinalizingStage (nodeWithStatements: TNodeWithStatements, callsGraphData: ICallsGraphData[]): void {
|
||||||
if (!this.stringArrayStorage.getLength()) {
|
if (!this.stringArrayStorage.getLength()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ export class CustomCodeHelpersTransformer extends AbstractNodeTransformer {
|
|||||||
.getStorage()
|
.getStorage()
|
||||||
.forEach((customCodeHelperGroup: ICustomCodeHelperGroup) => {
|
.forEach((customCodeHelperGroup: ICustomCodeHelperGroup) => {
|
||||||
customCodeHelperGroup.initialize();
|
customCodeHelperGroup.initialize();
|
||||||
customCodeHelperGroup.appendOnPreparing?.(node, this.callsGraphData);
|
customCodeHelperGroup.appendOnPreparingStage?.(node, this.callsGraphData);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -150,7 +150,7 @@ export class CustomCodeHelpersTransformer extends AbstractNodeTransformer {
|
|||||||
this.customCodeHelperGroupStorage
|
this.customCodeHelperGroupStorage
|
||||||
.getStorage()
|
.getStorage()
|
||||||
.forEach((customCodeHelperGroup: ICustomCodeHelperGroup) => {
|
.forEach((customCodeHelperGroup: ICustomCodeHelperGroup) => {
|
||||||
const methodName = <TCustomCodeHelpersGroupAppendMethodName>`appendOn${nodeTransformationStage}`;
|
const methodName = <TCustomCodeHelpersGroupAppendMethodName>`appendOn${nodeTransformationStage}Stage`;
|
||||||
|
|
||||||
customCodeHelperGroup[methodName]?.(node, this.callsGraphData);
|
customCodeHelperGroup[methodName]?.(node, this.callsGraphData);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
import { NodeTransformationStage } from '../../enums/node-transformers/NodeTransformationStage';
|
import { NodeTransformationStage } from '../../enums/node-transformers/NodeTransformationStage';
|
||||||
|
|
||||||
export type TCustomCodeHelpersGroupAppendMethodName = `appendOn${Capitalize<NodeTransformationStage>}`;
|
export type TCustomCodeHelpersGroupAppendMethodName = `appendOn${Capitalize<NodeTransformationStage>}Stage`;
|
||||||
|
|||||||
Reference in New Issue
Block a user