diff options
author | Evan Prodromou <evan@prodromou.name> | 2008-07-07 03:44:34 -0400 |
---|---|---|
committer | Evan Prodromou <evan@prodromou.name> | 2008-07-07 03:44:34 -0400 |
commit | 8688d707ebbac87851b1f60fde63b0dbb6b199a3 (patch) | |
tree | e03d7d34afade5445ff07dfbec01aadad89353d3 /lib | |
parent | 834df790ceb2a6a3425e934ec877963f896ebca4 (diff) |
better error reporting
darcs-hash:20080707074434-84dde-ffc9b2caeef3e9fef9607511b425880986883d72.gz
Diffstat (limited to 'lib')
-rw-r--r-- | lib/util.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/util.php b/lib/util.php index 3301c0233..638bd0333 100644 --- a/lib/util.php +++ b/lib/util.php @@ -852,7 +852,9 @@ function common_save_replies($notice) { } $id = $reply->insert(); if (!$id) { - common_log_db_error($reply, 'INSERT', __FILE__); + $last_error = &PEAR::getStaticProperty('DB_DataObject','lastError'); + common_log(LOG_ERROR, 'DB error inserting reply: ' . $last_error->message); + common_server_error('DB error inserting reply: ' . $last_error->message); return; } } |