diff --git a/darkmode.js b/darkmode.js index d203802..b2a8704 100644 --- a/darkmode.js +++ b/darkmode.js @@ -19,13 +19,8 @@ function setDarkMode(darkMode) { } } -function loadDarkMode() { +let storage = window.localStorage; - (function() { - let storage = window.localStorage; - - if (storage.getItem("dark-mode") != null) { - setDarkMode(storage.getItem("dark-mode") === "true"); - } - }()); -}; +if (storage.getItem("dark-mode") != null) { + setDarkMode(storage.getItem("dark-mode") === "true"); +} diff --git a/stroll.html b/stroll.html index 50c916a..8172773 100644 --- a/stroll.html +++ b/stroll.html @@ -5,7 +5,6 @@