From 61162523d0987e3d4b8347a3209d8e8313c8dbc1 Mon Sep 17 00:00:00 2001 From: glo85315 <159006137+glo85315@users.noreply.github.com> Date: Fri, 12 Jul 2024 12:53:58 +0530 Subject: [PATCH] PWA-3243 :PWA Store View Not Functioning for Taiwan Store View with Language Locale 'zh_Hant_TW' (#4273) Co-authored-by: rudraswamy.c --- packages/venia-ui/lib/util/formatLocale.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/venia-ui/lib/util/formatLocale.js b/packages/venia-ui/lib/util/formatLocale.js index b10550af3b..3539c67361 100644 --- a/packages/venia-ui/lib/util/formatLocale.js +++ b/packages/venia-ui/lib/util/formatLocale.js @@ -15,5 +15,5 @@ export const fromReactIntl = string => { * @returns {string} A string (e.g. `fr-FR`). */ export const toReactIntl = string => { - return string.replace('_', '-'); + return string.replace(/_/g, '-'); };