LibWeb: Add a default for the navigator's languages

This will mean that non-Qt frontends don't return an empty array.
This commit is contained in:
Jamie Mansfield 2024-07-26 16:51:12 +01:00 committed by Andreas Kling
parent 89a4fa4d24
commit 7b105e1ecf
Notes: github-actions[bot] 2024-07-27 06:19:12 +00:00

View file

@ -126,7 +126,7 @@ private:
NonnullRefPtr<ResourceLoaderConnector> m_connector; NonnullRefPtr<ResourceLoaderConnector> m_connector;
String m_user_agent; String m_user_agent;
String m_platform; String m_platform;
Vector<String> m_preferred_languages; Vector<String> m_preferred_languages = { "en"_string };
NavigatorCompatibilityMode m_navigator_compatibility_mode; NavigatorCompatibilityMode m_navigator_compatibility_mode;
bool m_enable_do_not_track { false }; bool m_enable_do_not_track { false };
Optional<JS::GCPtr<Page>> m_page {}; Optional<JS::GCPtr<Page>> m_page {};