always use mdb2 for installation
This commit is contained in:
parent
b86367866e
commit
39fa5d1c7f
1 changed files with 1 additions and 2 deletions
|
@ -43,13 +43,12 @@ class OC_DB {
|
||||||
* Connects to the database as specified in config.php
|
* Connects to the database as specified in config.php
|
||||||
*/
|
*/
|
||||||
public static function connect(){
|
public static function connect(){
|
||||||
if(class_exists('PDO')){//check if we can use PDO, else use MDB2
|
if(class_exists('PDO') && OC_Config::getValue('installed', false)){//check if we can use PDO, else use MDB2 (instalation always needs to be done my mdb2)
|
||||||
self::connectPDO();
|
self::connectPDO();
|
||||||
self::$connection=self::$PDO;
|
self::$connection=self::$PDO;
|
||||||
self::$backend=self::BACKEND_PDO;
|
self::$backend=self::BACKEND_PDO;
|
||||||
}else{
|
}else{
|
||||||
self::connectMDB2();
|
self::connectMDB2();
|
||||||
die('bar');
|
|
||||||
self::$connection=self::$MDB2;
|
self::$connection=self::$MDB2;
|
||||||
self::$backend=self::BACKEND_MDB2;
|
self::$backend=self::BACKEND_MDB2;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue