Followup r92430 per CR, like r94448

This commit is contained in:
Sam Reed 2011-08-15 18:56:37 +00:00
parent 95300b2e55
commit 9f785bc597
2 changed files with 4 additions and 1 deletions

View file

@ -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();

View file

@ -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();