From: Niklas Laxström Date: Sat, 13 Jun 2009 08:57:33 +0000 (+0000) Subject: Follow-up to r?????: X-Git-Tag: 1.31.0-rc.0~41391 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/password.php?a=commitdiff_plain;h=ea0f52679f02b4dbc44000453604d58c2899cc3b;p=lhc%2Fweb%2Fwiklou.git Follow-up to r?????: PHP Catchable fatal error: Argument 1 passed to DBError::__construct() must be an instance of Database, instance of DatabaseMysql given, called in /var/www/w/includes/db/Database.php on line 2736 and defined in /var/www/w/includes/db/Database.php on line 2547 --- diff --git a/includes/db/Database.php b/includes/db/Database.php index 7bb5223584..fe31766c9e 100644 --- a/includes/db/Database.php +++ b/includes/db/Database.php @@ -2560,7 +2560,7 @@ class DBError extends MWException { * @param $db Database object which threw the error * @param $error A simple error message to be used for debugging */ - function __construct( Database &$db, $error ) { + function __construct( DatabaseBase &$db, $error ) { $this->db =& $db; parent::__construct( $error ); } @@ -2572,7 +2572,7 @@ class DBError extends MWException { class DBConnectionError extends DBError { public $error; - function __construct( Database &$db, $error = 'unknown error' ) { + function __construct( DatabaseBase &$db, $error = 'unknown error' ) { $msg = 'DB connection error'; if ( trim( $error ) != '' ) { $msg .= ": $error";