aboutsummaryrefslogtreecommitdiff
path: root/src/preload.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/preload.ts')
-rw-r--r--src/preload.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/preload.ts b/src/preload.ts
index 820b655..b75574a 100644
--- a/src/preload.ts
+++ b/src/preload.ts
@@ -54,7 +54,9 @@ if (location.protocol !== "data:") {
document.getElementById("vencord-css-core")!.textContent = readFileSync(rendererCss, "utf-8");
});
}
- require(process.env.DISCORD_PRELOAD!);
+
+ if (process.env.DISCORD_PRELOAD)
+ require(process.env.DISCORD_PRELOAD);
} else {
// Monaco Popout
contextBridge.exposeInMainWorld("setCss", debounce(s => VencordNative.ipc.invoke(IpcEvents.SET_QUICK_CSS, s)));