2012-06-12, 05:35 AM
Hi,
it would be nice, if you could fix the PHP Notice errors in db_mysqli.php. These are only very small changes. Maybe they can be included in the next bugfix version.
line 169:
line 198:
This one will only be raised, if for any reason $mybb isn't defined. This will never happen in the productive system, but using the database object itself in a plugin or development process, this may happen.
line 324:
it would be nice, if you could fix the PHP Notice errors in db_mysqli.php. These are only very small changes. Maybe they can be included in the next bugfix version.
line 169:
if(!is_array($connections[$type]))
{
break;
}
changed toif(!isset($connections[$type]) || !is_array($connections[$type]))
{
break;
}
line 198:
// Specified a custom port for this connection?
list($hostname, $port) = explode(":", $single_connection['hostname'], 2);
if($port)
{
$this->$link = @$connect_function($persist.$hostname, $single_connection['username'], $single_connection['password'], "", $port);
}
changed to// Specified a custom port for this connection?
$host = explode(":", $single_connection['hostname'], 2);
if(isset($host[1]))
{
$this->$link = @$connect_function($persist.$hostname, $single_connection['username'], $single_connection['password'], "", $host[1]);
}
This one will only be raised, if for any reason $mybb isn't defined. This will never happen in the productive system, but using the database object itself in a plugin or development process, this may happen.
line 324:
if($mybb->debug_mode)
{
$this->explain_query($string, $query_time);
}
changed toif(!empty($mybb) && $mybb->debug_mode)
{
$this->explain_query($string, $query_time);
}