1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-02 19:05:55 +02:00
This commit is contained in:
syuilo
2018-05-17 15:41:07 +09:00
parent a090d6e820
commit 5c38084af5
4 changed files with 7 additions and 3 deletions

View File

@@ -32,7 +32,7 @@
// Detect the user language
// Note: The default language is Japanese
let lang = navigator.language.split('-')[0];
if (!/^(en|ja)$/.test(lang)) lang = 'ja';
if (!LANGS.includes(lang)) lang = 'en';
if (localStorage.getItem('lang')) lang = localStorage.getItem('lang');
// Detect the user agent