From 8470acda41927a4f9d96bf5c81231a60eb30c2d4 Mon Sep 17 00:00:00 2001 From: Cohee <18619528+Cohee1207@users.noreply.github.com> Date: Tue, 15 Aug 2023 21:47:49 +0300 Subject: [PATCH] Add English language option --- public/index.html | 1 + public/scripts/power-user.js | 13 ++++--------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/public/index.html b/public/index.html index 23ddcb30e..22ece5dd6 100644 --- a/public/index.html +++ b/public/index.html @@ -2371,6 +2371,7 @@ + diff --git a/public/scripts/power-user.js b/public/scripts/power-user.js index 4a6edd4f6..f72566dda 100644 --- a/public/scripts/power-user.js +++ b/public/scripts/power-user.js @@ -2068,17 +2068,12 @@ $(document).ready(() => { if (language) { localStorage.setItem(storage_keys.ui_language, language); - window["applyLocale"](); } else { - const result = confirm("Are you sure you want to reset the language to default? This will reload the page.") - if (result) { - localStorage.removeItem(storage_keys.ui_language); - location.reload(); - } else { - $(this).val(localStorage.getItem(storage_keys.ui_language)); - } + localStorage.removeItem(storage_keys.ui_language); } - }) + + location.reload(); + }); $(window).on('focus', function () { browser_has_focus = true;