diff --git a/locales/index.js b/locales/index.js
index 0910749bbf..ea0c101952 100644
--- a/locales/index.js
+++ b/locales/index.js
@@ -15,7 +15,7 @@ const langs = {
 	'en': loadLang('en'),
 	'fr': loadLang('fr'),
 	'ja': native,
-	'ja-ks': loadLang('ja-ks'),
+	'ja-KS': loadLang('ja-KS'),
 	'pl': loadLang('pl'),
 	'es': loadLang('es')
 };
diff --git a/locales/ja-ks.yml b/locales/ja-KS.yml
similarity index 100%
rename from locales/ja-ks.yml
rename to locales/ja-KS.yml
diff --git a/src/client/app/boot.js b/src/client/app/boot.js
index 218d57d8ef..952881f6cb 100644
--- a/src/client/app/boot.js
+++ b/src/client/app/boot.js
@@ -32,13 +32,15 @@
 	//#region Detect app name
 	let app = null;
 
-	if (url.pathname == '/docs' || url.pathname.startsWith('/docs/')) app = 'docs';
-	if (url.pathname == '/dev' || url.pathname.startsWith('/dev/')) app = 'dev';
-	if (url.pathname == '/auth' || url.pathname.startsWith('/auth/')) app = 'auth';
+	if (`${url.pathname}/`.startsWith('/docs/')) app = 'docs';
+	if (`${url.pathname}/`.startsWith('/dev/')) app = 'dev';
+	if (`${url.pathname}/`.startsWith('/auth/')) app = 'auth';
 	//#endregion
 
 	//#region Detect the user language
-	let lang = navigator.language.split('-')[0];
+	let lang = navigator.language;
+
+	if (!LANGS.includes(lang)) lang = lang.split('-')[0];
 
 	// The default language is English
 	if (!LANGS.includes(lang)) lang = 'en';