r55163 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r55162‎ | r55163 | r55164 >
Date:02:46, 17 August 2009
Author:aaron
Status:ok
Tags:
Comment:
fixed missing title bug
Modified paths:
  • /trunk/phase3/maintenance/rebuildFileCache.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/rebuildFileCache.php
@@ -32,7 +32,8 @@
3333 }
3434
3535 public function execute() {
36 - global $wgUseFileCache, $wgContentNamespaces, $wgDisableCounters, $wgTitle, $wgArticle, $wgOut;
 36+ global $wgUseFileCache, $wgDisableCounters, $wgContentNamespaces;
 37+ global $wgTitle, $wgArticle, $wgOut, $wgUser;
3738 if( !$wgUseFileCache ) {
3839 $this->error( "Nothing to do -- \$wgUseFileCache is disabled.", true );
3940 }
@@ -73,9 +74,11 @@
7475 $rebuilt = false;
7576 $wgTitle = Title::makeTitleSafe( $row->page_namespace, $row->page_title );
7677 if( null == $wgTitle ) {
77 - $this->output( "Page {$row->page_id} bad title\n" );
 78+ $this->output( "Page {$row->page_id} has bad title\n" );
7879 continue; // broken title?
7980 }
 81+ $wgOut->setTitle( $wgTitle ); // set display title
 82+ $wgUser->getSkin( $wgTitle ); // set skin title
8083 $wgArticle = new Article( $wgTitle );
8184 // If the article is cacheable, then load it
8285 if( $wgArticle->isFileCacheable() ) {

Status & tagging log