Skip to content

Commit

Permalink
[betterdiscord] remove unnecessary patch
Browse files Browse the repository at this point in the history
  • Loading branch information
ioj4 committed Feb 6, 2025
1 parent 21a3fcb commit a2d84f2
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions branches/mod/betterdiscord/meta.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,5 @@ export async function setup(target, log) {
await rm(asarPath, { force: true });
await fileRes.body.pipeTo(Writable.toWeb(createWriteStream(asarPath)));

log("Patching out platform checks...");

// patch out platform check; extract everything
const exPath = join(target, "ex");
extractAll(asarPath, exPath);
const istr = await readFile(join(target, "ex/injector.js"), "utf8");

const patched = istr.replaceAll(/"win32"==process.platform|"darwin"==process.platform/g, "false");

await writeFile(join(target, "ex/injector.js"), patched);

await createPackage(exPath, asarPath);

rmSync(exPath, { recursive: true });

log("Done!");
}

0 comments on commit a2d84f2

Please sign in to comment.