From: Sam Reed Date: Mon, 15 Aug 2011 18:56:37 +0000 (+0000) Subject: Followup r92430 per CR, like r94448 X-Git-Tag: 1.31.0-rc.0~28250 X-Git-Url: http://git.cyclocoop.org/url?a=commitdiff_plain;h=9f785bc59780c06a429bbb4e4d423b9f1945d23f;p=lhc%2Fweb%2Fwiklou.git Followup r92430 per CR, like r94448 --- diff --git a/includes/SpecialPage.php b/includes/SpecialPage.php index ec257b9f79..43ade67213 100644 --- a/includes/SpecialPage.php +++ b/includes/SpecialPage.php @@ -545,7 +545,7 @@ class SpecialPage { if ( $this->userCanExecute( $this->getUser() ) ) { $func = $this->mFunction; // only load file if the function does not exist - if(!is_callable($func) and $this->mFile) { + if( !is_callable($func) && $this->mFile ) { require_once( $this->mFile ); } $this->outputHeader(); diff --git a/includes/api/ApiParamInfo.php b/includes/api/ApiParamInfo.php index 259443a92c..ad380c5412 100644 --- a/includes/api/ApiParamInfo.php +++ b/includes/api/ApiParamInfo.php @@ -123,6 +123,9 @@ class ApiParamInfo extends ApiBase { $result->setIndexedTagName( $retval['helpurls'], 'helpurl' ); $retval['allexamples'] = $examples; + if ( isset( $retval['allexamples'][0] ) && $retval['allexamples'][0] === false ) { + $retval['allexamples'] = array(); + } $result->setIndexedTagName( $retval['allexamples'], 'example' ); $retval['parameters'] = array();