this probably works
This commit is contained in:
parent
52484e5d72
commit
0af17d1dae
1 changed files with 4 additions and 2 deletions
|
|
@ -21,6 +21,7 @@ import { IpcEvents } from "@shared/IpcEvents";
|
|||
import { VENCORD_USER_AGENT } from "@shared/vencordUserAgent";
|
||||
import { ipcMain } from "electron";
|
||||
import { closeSync, fsyncSync, openSync, writeFileSync as originalWriteFileSync } from "original-fs";
|
||||
import { join } from "path";
|
||||
|
||||
import gitHash from "~git-hash";
|
||||
import gitRemote from "~git-remote";
|
||||
|
|
@ -72,9 +73,10 @@ async function applyUpdates() {
|
|||
if (!PendingUpdate) return true;
|
||||
|
||||
const data = await fetchBuffer(PendingUpdate);
|
||||
originalWriteFileSync(__dirname, data);
|
||||
const asarPath = join(__dirname, ASAR_FILE);
|
||||
originalWriteFileSync(asarPath, data);
|
||||
|
||||
const fd = openSync(__dirname, "r");
|
||||
const fd = openSync(asarPath, "r");
|
||||
fsyncSync(fd);
|
||||
closeSync(fd);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue