Index: trunk/phase3/includes/Title.php |
— | — | @@ -1278,19 +1278,26 @@ |
1279 | 1279 | if( $this->isSpecial( 'Userlogin' ) || $this->isSpecial( 'Resetpass' ) ) { |
1280 | 1280 | return true; |
1281 | 1281 | } |
| 1282 | + |
| 1283 | + /** |
| 1284 | + * Bail out if there isn't whitelist |
| 1285 | + */ |
| 1286 | + if( !is_array($wgWhitelistRead) ) { |
| 1287 | + return false; |
| 1288 | + } |
1282 | 1289 | |
1283 | 1290 | /** |
1284 | 1291 | * Check for explicit whitelisting |
1285 | 1292 | */ |
1286 | 1293 | $name = $this->getPrefixedText(); |
1287 | | - if( $wgWhitelistRead && in_array( $name, $wgWhitelistRead, true ) ) |
| 1294 | + if( in_array( $name, $wgWhitelistRead, true ) ) |
1288 | 1295 | return true; |
1289 | 1296 | |
1290 | 1297 | /** |
1291 | 1298 | * Old settings might have the title prefixed with |
1292 | 1299 | * a colon for main-namespace pages |
1293 | 1300 | */ |
1294 | | - if( $wgWhitelistRead && $this->getNamespace() == NS_MAIN ) { |
| 1301 | + if( $this->getNamespace() == NS_MAIN ) { |
1295 | 1302 | if( in_array( ':' . $name, $wgWhitelistRead ) ) |
1296 | 1303 | return true; |
1297 | 1304 | } |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -54,6 +54,8 @@ |
55 | 55 | * Speed up Special:UncategorizedPages and Special:Deadendpages (no longer marked |
56 | 56 | as slow queries). They now add blank ('','') entries for pages without ANY links |
57 | 57 | or categories. |
| 58 | +* Fixed notice when accessing special page without read permission and whitelist |
| 59 | + is not defined |
58 | 60 | |
59 | 61 | === API changes in 1.12 === |
60 | 62 | |