From: Evan Prodromou Date: Wed, 7 Apr 2010 14:43:14 +0000 (-0400) Subject: show PEAR_Error message, not the object X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=82326a3b690552cccd8c82950b7653556f6522c1;p=quix0rs-gnu-social.git show PEAR_Error message, not the object --- diff --git a/classes/Memcached_DataObject.php b/classes/Memcached_DataObject.php index bc4c3a000c..920966b16d 100644 --- a/classes/Memcached_DataObject.php +++ b/classes/Memcached_DataObject.php @@ -505,6 +505,9 @@ class Memcached_DataObject extends Safe_DataObject if ($this->id) { $id .= ':' . $this->id; } + if ($message instanceof PEAR_Error) { + $message = $message->getMessage(); + } throw new ServerException("[$id] DB_DataObject error [$type]: $message"); }