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; }