fix: TypeError: Cannot read properties of null (reading 'config') (#12356)
This commit is contained in:
@@ -21,6 +21,9 @@ const articleUiFlags = useMapGetter('article/uiFlags');
|
||||
|
||||
const locale = computed(() => {
|
||||
const { locale: selectedLocale } = i18n;
|
||||
|
||||
if (!portal.value || !portal.value.config) return null;
|
||||
|
||||
const { allowed_locales: allowedLocales } = portal.value.config;
|
||||
return getMatchingLocale(selectedLocale.value, allowedLocales);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user