r25776 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r25775‎ | r25776 | r25777 >
Date:14:46, 11 September 2007
Author:nikerabbit
Status:old
Tags:
Comment:
* Fixed notice when accessing special page without read permission and whitelist is not defined
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/Title.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Title.php
@@ -1278,19 +1278,26 @@
12791279 if( $this->isSpecial( 'Userlogin' ) || $this->isSpecial( 'Resetpass' ) ) {
12801280 return true;
12811281 }
 1282+
 1283+ /**
 1284+ * Bail out if there isn't whitelist
 1285+ */
 1286+ if( !is_array($wgWhitelistRead) ) {
 1287+ return false;
 1288+ }
12821289
12831290 /**
12841291 * Check for explicit whitelisting
12851292 */
12861293 $name = $this->getPrefixedText();
1287 - if( $wgWhitelistRead && in_array( $name, $wgWhitelistRead, true ) )
 1294+ if( in_array( $name, $wgWhitelistRead, true ) )
12881295 return true;
12891296
12901297 /**
12911298 * Old settings might have the title prefixed with
12921299 * a colon for main-namespace pages
12931300 */
1294 - if( $wgWhitelistRead && $this->getNamespace() == NS_MAIN ) {
 1301+ if( $this->getNamespace() == NS_MAIN ) {
12951302 if( in_array( ':' . $name, $wgWhitelistRead ) )
12961303 return true;
12971304 }
Index: trunk/phase3/RELEASE-NOTES
@@ -54,6 +54,8 @@
5555 * Speed up Special:UncategorizedPages and Special:Deadendpages (no longer marked
5656 as slow queries). They now add blank ('','') entries for pages without ANY links
5757 or categories.
 58+* Fixed notice when accessing special page without read permission and whitelist
 59+ is not defined
5860
5961 === API changes in 1.12 ===
6062

Follow-up revisions

RevisionCommit summaryAuthorDate
r25804Merged revisions 25752-25803 via svnmerge from...david02:25, 12 September 2007

Status & tagging log