X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=application%2FLanguages.php;h=3eb3388f48f6a01ac87c872c408018c9c574cdec;hb=b7c412d4d0fec7f3f54ecaa09178afa16c779d7e;hp=357c7524ed458a128148522b124dd17876faac87;hpb=2cbf4acddeeed9d6d775566b1dec560b1452d8eb;p=github%2Fshaarli%2FShaarli.git diff --git a/application/Languages.php b/application/Languages.php index 357c7524..3eb3388f 100644 --- a/application/Languages.php +++ b/application/Languages.php @@ -69,6 +69,8 @@ class Languages { $this->conf = $conf; $confLanguage = $this->conf->get('translation.language', 'auto'); + // Auto mode or invalid parameter, use the detected language. + // If the detected language is invalid, it doesn't matter, it will use English. if ($confLanguage === 'auto' || ! $this->isValidLanguage($confLanguage)) { $this->language = substr($language, 0, 5); } else {