diff --git a/preload.js b/preload.js index 92be85f..1213095 100644 --- a/preload.js +++ b/preload.js @@ -2,13 +2,13 @@ const customTitlebar = require("custom-electron-titlebar"); const electronLocalshortcut = require("electron-localshortcut"); const { remote } = require("electron"); const ArmCord = require("./utils/ArmCord.js"); - +require("./utils/theme.js"); window.addEventListener("DOMContentLoaded", () => { new customTitlebar.Titlebar({ backgroundColor: customTitlebar.Color.fromHex("#202225"), menu: false, }); - require("./utils/theme.js"); + const currentWindow = remote.getCurrentWindow(); electronLocalshortcut.register(currentWindow, "F5", () => { location.reload(); diff --git a/utils/theme.js b/utils/theme.js index 8d0ce72..0cd3774 100644 --- a/utils/theme.js +++ b/utils/theme.js @@ -1,8 +1,8 @@ const fs = require("fs"); const armcord = require("./armcord.js"); const themeFolder = __dirname + "/themes/"; -console.log("Theme Module Loaded") window.addEventListener("DOMContentLoaded", () => { + console.log("Theme Module Loaded"); fs.readdirSync(themeFolder).forEach((file) => { console.log(file); try {