From 0a820a0533272db82cad41f244cfafebc0815d8c Mon Sep 17 00:00:00 2001 From: Frudrax Cheng Date: Mon, 23 Dec 2024 11:42:54 +0800 Subject: [PATCH] Update deviceLocales.ts --- src/locale/deviceLocales.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/locale/deviceLocales.ts b/src/locale/deviceLocales.ts index 7827fecd31..b9ab8bab20 100644 --- a/src/locale/deviceLocales.ts +++ b/src/locale/deviceLocales.ts @@ -41,17 +41,11 @@ export function getLocales() { } if (typeof locale.languageTag === 'string') { - if ( - locale.languageTag === 'zh-CN' || - locale.languageTag.startsWith('zh-Hans') - ) { + if (locale.languageTag === 'zh-CN') { // Simplified Chinese to zh-Hans-CN locale.languageTag = 'zh-Hans-CN' } - if ( - locale.languageTag === 'zh-TW' || - locale.languageTag.startsWith('zh-Hant') - ) { + if (locale.languageTag === 'zh-TW') { // Traditional Chinese to zh-Hant-TW locale.languageTag = 'zh-Hant-TW' }