From 70cfa80ed7f43e8915b3b46ced4f34aebfe50b1f Mon Sep 17 00:00:00 2001 From: quenousimporte Date: Thu, 16 Nov 2023 10:50:29 +0100 Subject: [PATCH] refactor --- main.js | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/main.js b/main.js index 423ffc2..0301b5e 100644 --- a/main.js +++ b/main.js @@ -1275,14 +1275,6 @@ function loadstorage() } } -function applystyle() -{ - document.body.style.fontSize = settings.fontsize; - document.body.style.lineHeight = settings.lineheight; - document.body.style.marginLeft = settings.margins; - document.body.style.marginRight = settings.margins; -} - function loadsettings() { settings = {...defaultsettings}; @@ -1299,7 +1291,10 @@ function loadsettings() } } - applystyle(); + document.body.style.fontSize = settings.fontsize; + document.body.style.lineHeight = settings.lineheight; + document.body.style.marginLeft = settings.margins; + document.body.style.marginRight = settings.margins; if (settings.titlebydefault && title.hidden) {