summaryrefslogtreecommitdiffstats
path: root/dist/js
diff options
context:
space:
mode:
Diffstat (limited to 'dist/js')
-rwxr-xr-xdist/js/app.js2
-rw-r--r--dist/js/settings.js10
2 files changed, 9 insertions, 3 deletions
diff --git a/dist/js/app.js b/dist/js/app.js
index e935a0f..07197bb 100755
--- a/dist/js/app.js
+++ b/dist/js/app.js
@@ -3,7 +3,7 @@
const app_version = "1.0.13-beta";
-const previous_commit = "c721f2fd02613a5f8d5beb3b66a3681542da2048";
+const previous_commit = "f4aa5ca7f0ee77f5b26ff3f9d1b5c9f25cd1d2cb";
if ("serviceWorker" in navigator) {
navigator.serviceWorker.register("/sw.js")
diff --git a/dist/js/settings.js b/dist/js/settings.js
index 5712039..b53d2ce 100644
--- a/dist/js/settings.js
+++ b/dist/js/settings.js
@@ -25,12 +25,18 @@ document.addEventListener("DOMContentLoaded", async () => {
});
localforage.getItem("chosenLang").then((value) => {
- let selectedLanguage = value ?? "sl";
+ let selectedLanguage = value;
+ if(value == null || value.length < 1) {
+ selectedLanguage = "sl";
+ }
$(`#option-${selectedLanguage}`).attr("selected", true);
}).catch(() => {});
localforage.getItem("theme").then((value) => {
- let selectedTheme = value ?? "themeLight";
+ let selectedTheme = value;
+ if(value == null || value.length < 1) {
+ selectedTheme = "themeLight";
+ }
$(`#option-${selectedTheme}`).attr("selected", true);
}).catch(() => {});