chore: fix ui tests

This commit is contained in:
Michael Geers 2024-01-27 16:49:33 +01:00
parent 47b3bd485a
commit de9c956731

View file

@ -36,7 +36,7 @@ export const LOCALES = {
export const DEFAULT_LOCALE = "en";
const htmlLang = document.querySelector("html").getAttribute("lang");
const DEFAULT_BROWSER_LOCALE = htmlLang.length == 2 ? htmlLang : DEFAULT_LOCALE;
const DEFAULT_BROWSER_LOCALE = htmlLang?.length == 2 ? htmlLang : DEFAULT_LOCALE;
export function getLocalePreference() {
return settings.locale;