diff --git a/system/functions.php b/system/functions.php index 0fcc6aa4..97779601 100644 --- a/system/functions.php +++ b/system/functions.php @@ -754,10 +754,10 @@ function get_browser_languages() { $ret = array(); - $acceptLang = $_SERVER['HTTP_ACCEPT_LANGUAGE']; - if(!isset($acceptLang[0])) + if(empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) return $ret; + $acceptLang = $_SERVER['HTTP_ACCEPT_LANGUAGE']; $languages = strtolower($acceptLang); // $languages = 'pl,en-us;q=0.7,en;q=0.3 '; // need to remove spaces from strings to avoid error