mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-19 21:15:14 +00:00
change log string on pdo log messages
This commit is contained in:
parent
2b3b5d2c8a
commit
b5c72611b4
1 changed files with 3 additions and 3 deletions
|
@ -60,7 +60,7 @@ class dba_pdo extends dba_driver {
|
|||
|
||||
$this->error = $e->getMessage();
|
||||
if($this->error) {
|
||||
db_logger('dba_mysqli: ERROR: ' . printable($sql) . "\n" . $this->error, LOGGER_NORMAL, LOG_ERR);
|
||||
db_logger('dba_pdo: ERROR: ' . printable($sql) . "\n" . $this->error, LOGGER_NORMAL, LOG_ERR);
|
||||
if(file_exists('dbfail.out')) {
|
||||
file_put_contents('dbfail.out', datetime_convert() . "\n" . printable($sql) . "\n" . $this->error . "\n", FILE_APPEND);
|
||||
}
|
||||
|
@ -69,13 +69,13 @@ class dba_pdo extends dba_driver {
|
|||
|
||||
if(!($select)) {
|
||||
if($this->debug) {
|
||||
db_logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returns ' . (($result) ? 'true' : 'false'), LOGGER_NORMAL,(($result) ? LOG_INFO : LOG_ERR));
|
||||
db_logger('dba_pdo: DEBUG: ' . printable($sql) . ' returns ' . (($result) ? 'true' : 'false'), LOGGER_NORMAL,(($result) ? LOG_INFO : LOG_ERR));
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
|
||||
if($this->debug) {
|
||||
db_logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returned ' . count($result) . ' results.', LOGGER_NORMAL, LOG_INFO);
|
||||
db_logger('dba_pdo: DEBUG: ' . printable($sql) . ' returned ' . count($result) . ' results.', LOGGER_NORMAL, LOG_INFO);
|
||||
}
|
||||
|
||||
$r = array();
|
||||
|
|
Loading…
Reference in a new issue