From 2fbae5c3369f57e17079e5ad1248f4953c7a67ee Mon Sep 17 00:00:00 2001 From: nbm Date: Tue, 18 Oct 2005 12:11:15 +0000 Subject: [PATCH] If _bUsePearError is set, return a PEAR error instead of false. --- lib/ktentity.inc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/ktentity.inc b/lib/ktentity.inc index 14d9216..f1c8958 100644 --- a/lib/ktentity.inc +++ b/lib/ktentity.inc @@ -84,8 +84,12 @@ class KTEntity { if ($this->iId >= 0) { $res = DBUtil::autoDelete($this->_table(), $this->iId); if (PEAR::isError($res)) { - $_SESSION['errorMessage'] = $res->toString(); - return false; + if ($this->_bUsePearError === false) { + $_SESSION['errorMessage'] = $res->toString(); + return false; + } else { + return $res; + } } return true; } -- libgit2 0.21.4