diff --git a/packages/common/utils/index.ts b/packages/common/utils/index.ts index 41c286d38b..950003bcbd 100644 --- a/packages/common/utils/index.ts +++ b/packages/common/utils/index.ts @@ -276,6 +276,8 @@ export function getProviderTranslation(provider, t) { export function getLanguage(lng) { try { + if (!lng) return lng; + let language = lng == "en-US" || lng == "en-GB" ? "en" : lng; const splitted = lng.split("-");