1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-06 00:37:42 +02:00

[ticket/10205] Fix remaining db drivers.

PHPBB3-10205
This commit is contained in:
Oleg Pudeyev
2012-12-04 04:50:41 -05:00
parent 1a7e2211c3
commit 9f549e8249
5 changed files with 93 additions and 43 deletions

View File

@@ -300,10 +300,20 @@ class dbal_sqlite extends dbal
*/
function _sql_error()
{
return array(
'message' => @sqlite_error_string(@sqlite_last_error($this->db_connect_id)),
'code' => @sqlite_last_error($this->db_connect_id)
);
if (function_exists('sqlite_error_string'))
{
return array(
'message' => @sqlite_error_string(@sqlite_last_error($this->db_connect_id)),
'code' => @sqlite_last_error($this->db_connect_id)
);
}
else
{
return array(
'message' => $this->connect_error,
'code' => '',
);
}
}
/**