From: Alexandre Emsenhuber Date: Sat, 3 Apr 2010 21:07:57 +0000 (+0000) Subject: * Expand documentation a bit X-Git-Tag: 1.31.0-rc.0~37257 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/bilan.php?a=commitdiff_plain;h=6d42ca99c335d30d909c8173ae6464a813605758;p=lhc%2Fweb%2Fwiklou.git * Expand documentation a bit * Cast to boolean, since those functions should return boolean --- diff --git a/includes/Title.php b/includes/Title.php index 3feba538cb..09d68b23d8 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -3645,7 +3645,7 @@ class Title { // the full l10n of that language to be loaded. That takes much memory and // isn't needed. So we strip the language part away. list( $basename, /* rest */ ) = explode( '/', $this->mDbkeyform, 2 ); - return wfMsgWeirdKey( $basename ); // known system message + return (bool)wfMsgWeirdKey( $basename ); // known system message default: return false; } @@ -3673,11 +3673,13 @@ class Title { return true; if ( $this->mNamespace == NS_MEDIAWIKI ) { - // If the page is form Mediawiki:message/lang, calling wfMsgWeirdKey causes - // the full l10n of that language to be loaded. That takes much memory and - // isn't needed. So we strip the language part away. + // If the page doesn't exist but is a known system message, default + // message content will be displayed, same for language subpages + // Also, if the page is form Mediawiki:message/lang, calling wfMsgWeirdKey + // causes the full l10n of that language to be loaded. That takes much + // memory and isn't needed. So we strip the language part away. list( $basename, /* rest */ ) = explode( '/', $this->mDbkeyform, 2 ); - return wfMsgWeirdKey( $basename ); // known system message + return (bool)wfMsgWeirdKey( $basename ); } return false;