aboutsummaryrefslogtreecommitdiffstats
path: root/include/dba/dba_mysqli.php
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-03-07 20:43:52 -0800
committerredmatrix <git@macgirvin.com>2016-03-07 20:43:52 -0800
commit9debfa348aada8ad32a16cbba4f96cc8f4b0ac37 (patch)
tree6a92df1cbf3d5e92ed197c7eaa31e5680ae1b3a4 /include/dba/dba_mysqli.php
parent32e903e9560b3a6d1b133524493c3d72f384164c (diff)
downloadvolse-hubzilla-9debfa348aada8ad32a16cbba4f96cc8f4b0ac37.tar.gz
volse-hubzilla-9debfa348aada8ad32a16cbba4f96cc8f4b0ac37.tar.bz2
volse-hubzilla-9debfa348aada8ad32a16cbba4f96cc8f4b0ac37.zip
add syslog loglevels to dba functions
Diffstat (limited to 'include/dba/dba_mysqli.php')
-rwxr-xr-xinclude/dba/dba_mysqli.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/dba/dba_mysqli.php b/include/dba/dba_mysqli.php
index 74a999974..6986d4586 100755
--- a/include/dba/dba_mysqli.php
+++ b/include/dba/dba_mysqli.php
@@ -32,7 +32,7 @@ class dba_mysqli extends dba_driver {
if($this->error) {
- logger('dba_mysqli: ERROR: ' . printable($sql) . "\n" . $this->error);
+ logger('dba_mysqli: 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);
}
@@ -40,13 +40,13 @@ class dba_mysqli extends dba_driver {
if(($result === true) || ($result === false)) {
if($this->debug) {
- logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returns ' . (($result) ? 'true' : 'false'));
+ logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returns ' . (($result) ? 'true' : 'false'), LOGGER_NORMAL,(($result) ? LOG_INFO : LOG_ERR));
}
return $result;
}
if($this->debug) {
- logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returned ' . $result->num_rows . ' results.');
+ logger('dba_mysqli: DEBUG: ' . printable($sql) . ' returned ' . $result->num_rows . ' results.', LOGGER_NORMAL, LOG_INFO);
}
$r = array();
@@ -55,7 +55,7 @@ class dba_mysqli extends dba_driver {
$r[] = $x;
$result->free_result();
if($this->debug) {
- logger('dba_mysqli: ' . printable(print_r($r,true)));
+ logger('dba_mysqli: ' . printable(print_r($r,true)), LOGGER_NORMAL, LOG_INFO);
}
}
return $r;