Fixed error log warning (missing installed_extensions.inc) during upgrade to 2.2.
[fa-stable.git] / includes / session.inc
index 04acec518543dc53ddc940be48a8f0bc6ad933d3..f449407d9af302f698a555bb4d4810c8c86dec6d 100644 (file)
@@ -165,7 +165,7 @@ header("Cache-control: private");
 get_text_init();
 
 // Page Initialisation
-if (!isset($_SESSION['languages'])) 
+if (!isset($_SESSION['language'])) 
 {
        load_languages(); // sets also default $_SESSION['language']
 }
@@ -245,7 +245,8 @@ if (strstr($_SERVER['PHP_SELF'], 'logout.php') == false){
                }
        }
 
-       include_once($path_to_root . '/company/'.user_company().'/installed_extensions.php');
+       if (!$_SESSION["wa_current_user"]->old_db)
+               include_once($path_to_root . '/company/'.user_company().'/installed_extensions.php');
 
        if (!isset($_SESSION["App"])) {
                $_SESSION["App"] = new front_accounting();