summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--js/settings.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/js/settings.js b/js/settings.js
index fed7fe6..2e0e6ac 100644
--- a/js/settings.js
+++ b/js/settings.js
@@ -1,13 +1,14 @@
// settings.js -- TODO
async function setLanguage(langCode) {
- localforage.setItem("chosenLang", langCode).then( () => {
+ localforage.setItem("chosenLang", langCode).then((value) => {
+ console.log("Language set: " + value);
UIAlert(D("languageSet"), "setLanguage(): languageSet");
});
}
document.addEventListener("DOMContentLoaded", async () => {
- $(document).on("click", ".settings-language-selector", () => {
+ $(".settings-language-selector").click(function () {
let languageToSet = $(this).attr("data-language");
setLanguage(languageToSet);
});