From 946c439c289433c32d884eb48dbbd2dc99ae9d7e Mon Sep 17 00:00:00 2001 From: Matthew Hodgson Date: Thu, 21 Sep 2017 18:56:34 +0100 Subject: [PATCH] hopefully fix https://github.com/vector-im/riot-web/issues/4166 --- src/languageHandler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/languageHandler.js b/src/languageHandler.js index a19c796f39..4455d58b04 100644 --- a/src/languageHandler.js +++ b/src/languageHandler.js @@ -191,7 +191,7 @@ export function getAllLanguagesFromJson() { export function getLanguagesFromBrowser() { if (navigator.languages && navigator.languages.length) return navigator.languages; if (navigator.language) return [navigator.language]; - return [navigator.userLanguage]; + return [navigator.userLanguage || "en"]; } /**