mirror of
https://github.com/phpbb/phpbb.git
synced 2025-05-11 01:55:24 +02:00
DBAL extension motivated by #22125
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8414 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
540879ae41
commit
752b452128
@ -45,6 +45,8 @@ class dbal
|
||||
|
||||
// Holding the last sql query on sql error
|
||||
var $sql_error_sql = '';
|
||||
// Holding the error information - only populated if sql_error_triggered is set
|
||||
var $sql_error_returned = array();
|
||||
|
||||
// Holding transaction count
|
||||
var $transactions = 0;
|
||||
@ -544,11 +546,11 @@ class dbal
|
||||
$this->sql_error_triggered = true;
|
||||
$this->sql_error_sql = $sql;
|
||||
|
||||
$error = $this->_sql_error();
|
||||
$this->sql_error_returned = $this->_sql_error();
|
||||
|
||||
if (!$this->return_on_error)
|
||||
{
|
||||
$message = 'SQL ERROR [ ' . $this->sql_layer . ' ]<br /><br />' . $error['message'] . ' [' . $error['code'] . ']';
|
||||
$message = 'SQL ERROR [ ' . $this->sql_layer . ' ]<br /><br />' . $this->sql_error_returned['message'] . ' [' . $this->sql_error_returned['code'] . ']';
|
||||
|
||||
// Show complete SQL error and path to administrators only
|
||||
// Additionally show complete error on installation or if extended debug mode is enabled
|
||||
|
Loading…
x
Reference in New Issue
Block a user