From: Brion Vibber Date: Fri, 27 Nov 2009 22:20:57 +0000 (-0800) Subject: Log database errors when saving notice_inbox entries X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e85e47b509218117e8c454d698a5f7de2ff07812;p=quix0rs-gnu-social.git Log database errors when saving notice_inbox entries --- diff --git a/classes/Notice.php b/classes/Notice.php index ebb5022b99..3126cc0647 100644 --- a/classes/Notice.php +++ b/classes/Notice.php @@ -964,7 +964,10 @@ class Notice extends Memcached_DataObject } if ($cnt >= MAX_BOXCARS) { $inbox = new Notice_inbox(); - $inbox->query($qry); + $result = $inbox->query($qry); + if (PEAR::isError($result)) { + common_log_db_error($inbox, $qry); + } $qry = $qryhdr; $cnt = 0; } @@ -972,7 +975,10 @@ class Notice extends Memcached_DataObject if ($cnt > 0) { $inbox = new Notice_inbox(); - $inbox->query($qry); + $result = $inbox->query($qry); + if (PEAR::isError($result)) { + common_log_db_error($inbox, $qry); + } } return;