From 4b6fe78a1af008d26a4d34498699306e7609a9df Mon Sep 17 00:00:00 2001 From: Araxeus Date: Thu, 6 May 2021 18:40:56 +0300 Subject: [PATCH] fix css not inserting on reload --- plugins/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/utils.js b/plugins/utils.js index ed8c7c0a..b265692f 100644 --- a/plugins/utils.js +++ b/plugins/utils.js @@ -43,7 +43,7 @@ module.exports.fileExists = (path, callbackIfExists) => { }; module.exports.injectCSS = (webContents, filepath, cb = undefined) => { - webContents.once("did-finish-load", async () => { + webContents.on("did-finish-load", async () => { await webContents.insertCSS(fs.readFileSync(filepath, "utf8")); if (cb) { cb();