|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-06-06 11:10 UTC] mj@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 30 01:00:01 2025 UTC |
it would be helpful to know for sure whether PEAR_Frontend_CLI::displayError() accepts both strings and objects (a little @param string|object in a docblock would be helpful here). In any case, if you do pear info blah there is a call to a non-object because the source which is: function displayError($eobj) { return $this->_displayLine($eobj->getMessage()); } should be: /** * @param string Error Message */ function displayError($eobj) { return $this->_displayLine($eobj); } or: /** * @param object|string either an error message * or a class with a getMessage() method */ function displayError($eobj) { if (is_object($eobj) { return $this->_displayLine($eobj->getMessage()); } else { return $this->_displayLine($eobj); } } }