fix startup_gettext() trying to get configured language before session is initialized

master
Andrew Dolgov 12 years ago
parent efe46a3b53
commit 1ee4900a54

@ -95,8 +95,11 @@
$lang = _TRANSLATION_OVERRIDE_DEFAULT; $lang = _TRANSLATION_OVERRIDE_DEFAULT;
} }
if ($_SESSION["language"] && $_SESSION["language"] != "auto") { // startup_gettext() is called before session_start() so we can't rely
$lang = $_SESSION["language"]; // on $_SESSION['language'] here.
if ($_COOKIE["ttrss_lang"] && $_COOKIE["ttrss_lang"] != "auto") {
$lang = $_COOKIE["ttrss_lang"];
} }
if ($lang) { if ($lang) {

Loading…
Cancel
Save