X-Git-Url: http://git.dj3c1t.com/?a=blobdiff_plain;f=mw%2Fapp%2Fcontrollers%2Finstall%2Findex.php;h=79734f3fdf4f79eacdbd1ebabe00b72293982f54;hb=HEAD;hp=0f7b27c99c2c4727c6ce48ac375d38a9ff4f8dd9;hpb=5abc9d5fca28ef86dee6148bb96780d1a7b670f3;p=mtweb diff --git a/mw/app/controllers/install/index.php b/mw/app/controllers/install/index.php index 0f7b27c..79734f3 100644 --- a/mw/app/controllers/install/index.php +++ b/mw/app/controllers/install/index.php @@ -19,7 +19,7 @@ "email" => "", "password" => "" ); - if(($sgbds = $data->sgbds()) === false){ + if(($sgbds = $env->sgbds()) === false){ $env->erreur("impossible de lister les sgbds disponibles"); return; } @@ -77,14 +77,9 @@ else $env->message("merci de choisir un mot de passe pour l'administrateur"); if(!$env->messages()){ $sgbds[$current_sgbd] = null; - $impl = new $current_sgbd($params); + $impl = new $current_sgbd($env, $params); $sgbds[$current_sgbd] = $impl; - $data->set_sgbd( - new mw_sgbd( - $sgbds[$current_sgbd], - $env - ) - ); + $data->set_sgbd($sgbds[$current_sgbd]); $data->load_modules($env->path("mw_dir")."app/", "data/modules/".($current_sgbd == "mw_xml" ? "xml" : "sql")."/"); if( $current_sgbd == "mw_xml" @@ -196,12 +191,12 @@ if(!$plugin["installed"]){ $env->run("config/plugins/install", array("get" => array("id" => $plugin_name)), false); if($env->erreurs()) return; - $env->init_plugins("DESC", true); + $env->load_plugin($plugin_name); } if(!$plugin["enabled"]){ $env->run("config/plugins/enable", array("get" => array("id" => $plugin_name)), false); if($env->erreurs()) return; - $env->init_plugins("DESC", true); + $env->load_plugin($plugin_name); } } $env->redirect(