cvs: php4 /pear PEAR.php
| From: | Chuck Hagenbuch | Date: | Wed, 15 Aug 2001 21:26:13 +0000 |
| Subject: | cvs: php4 /pear PEAR.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-538@lists.php.net to get a copy of this message | ||
chagenbu Wed Aug 15 17:26:13 2001 EDT
Modified files:
/php4/pear PEAR.php
Log:
PEAR::raiseError() can be called statically - don't assume $this will be
there!
Index: php4/pear/PEAR.php
diff -u php4/pear/PEAR.php:1.13 php4/pear/PEAR.php:1.14
--- php4/pear/PEAR.php:1.13 Tue Aug 14 17:11:32 2001
+++ php4/pear/PEAR.php Wed Aug 15 17:26:12 2001
@@ -17,7 +17,7 @@
// | Stig Bakken <ssb@fast.no> |
// +----------------------------------------------------------------------+
//
-// $Id: PEAR.php,v 1.13 2001/08/14 21:11:32 ssb Exp $
+// $Id: PEAR.php,v 1.14 2001/08/15 21:26:12 chagenbu Exp $
//
define('PEAR_ERROR_RETURN', 1);
@@ -366,7 +366,7 @@
$message = $message->getMessage();
}
- if (sizeof($this->_expected_errors) > 0 && in_array($code,
end($this->_expected_errors))) {
+ if (isset($this) && isset($this->_expected_errors) &&
sizeof($this->_expected_errors) > 0 && in_array($code,
end($this->_expected_errors))) {
$mode = PEAR_ERROR_RETURN;
}