Changes:
- Database->$driver can no longer be NULL, an empty string is fine anyway
This commit is contained in:
parent
945cd1a2c2
commit
1080a840f5
|
@ -77,7 +77,7 @@ class DBA
|
|||
*
|
||||
* @return string with either "pdo" or "mysqli"
|
||||
*/
|
||||
public static function getDriver()
|
||||
public static function getDriver(): string
|
||||
{
|
||||
return DI::dba()->getDriver();
|
||||
}
|
||||
|
|
|
@ -64,7 +64,7 @@ class Database
|
|||
protected $server_info = '';
|
||||
/** @var PDO|mysqli */
|
||||
protected $connection;
|
||||
protected $driver;
|
||||
protected $driver = '';
|
||||
protected $pdo_emulate_prepares = false;
|
||||
private $error = false;
|
||||
private $errorno = 0;
|
||||
|
@ -181,7 +181,7 @@ class Database
|
|||
|
||||
// No suitable SQL driver was found.
|
||||
if (!$this->connected) {
|
||||
$this->driver = null;
|
||||
$this->driver = '';
|
||||
$this->connection = null;
|
||||
}
|
||||
|
||||
|
@ -233,7 +233,7 @@ class Database
|
|||
}
|
||||
}
|
||||
|
||||
$this->driver = null;
|
||||
$this->driver = '';
|
||||
$this->connected = false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user