This commit is contained in:
Nuckyz 2024-05-23 07:09:03 -03:00
parent 6567ff7435
commit 1013c34840
No known key found for this signature in database
GPG key ID: 440BF8296E1C4AD9

View file

@ -19,7 +19,7 @@ const initCallbackRegex = canonicalizeMatch(/{return \i\(".+?"\)}/);
const allProxiedModules = new Set<WebpackRequire["m"]>();
const modulesProxyhandler: ProxyHandler<WebpackRequire["m"]> = {
const modulesProxyHandler: ProxyHandler<WebpackRequire["m"]> = {
...Object.fromEntries(Object.getOwnPropertyNames(Reflect).map(propName =>
[propName, (...args: any[]) => Reflect[propName](...args)]
)),
@ -176,7 +176,7 @@ Object.defineProperty(Function.prototype, "m", {
// @ts-ignore
originalModules.$$proxiedModules = proxiedModules;
allProxiedModules.add(proxiedModules);
Object.setPrototypeOf(originalModules, new Proxy(proxiedModules, modulesProxyhandler));
Object.setPrototypeOf(originalModules, new Proxy(proxiedModules, modulesProxyHandler));
}
Object.defineProperty(this, "m", {