This commit is contained in:
thororen1234 2024-07-03 15:10:20 -04:00
commit efb0fee156
16 changed files with 470 additions and 190 deletions

View file

@ -260,7 +260,6 @@ function patchFactories(factories: Record<string, (module: any, exports: any, re
for (let i = 0; i < patches.length; i++) {
const patch = patches[i];
if (patch.predicate && !patch.predicate()) continue;
const moduleMatches = typeof patch.find === "string"
? code.includes(patch.find)
@ -276,8 +275,6 @@ function patchFactories(factories: Record<string, (module: any, exports: any, re
// We change all patch.replacement to array in plugins/index
for (const replacement of patch.replacement as PatchReplacement[]) {
if (replacement.predicate && !replacement.predicate()) continue;
const lastMod = mod;
const lastCode = code;