From 844040d985911d3eac858f0f0201555a70e1d975 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Mon, 17 Aug 2009 02:46:18 +0000 Subject: [PATCH] fixed missing title bug --- maintenance/rebuildFileCache.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/maintenance/rebuildFileCache.php b/maintenance/rebuildFileCache.php index 7c47c08d12..0d3596a442 100644 --- a/maintenance/rebuildFileCache.php +++ b/maintenance/rebuildFileCache.php @@ -32,7 +32,8 @@ class RebuildFileCache extends Maintenance { } public function execute() { - global $wgUseFileCache, $wgContentNamespaces, $wgDisableCounters, $wgTitle, $wgArticle, $wgOut; + global $wgUseFileCache, $wgDisableCounters, $wgContentNamespaces; + global $wgTitle, $wgArticle, $wgOut, $wgUser; if( !$wgUseFileCache ) { $this->error( "Nothing to do -- \$wgUseFileCache is disabled.", true ); } @@ -73,9 +74,11 @@ class RebuildFileCache extends Maintenance { $rebuilt = false; $wgTitle = Title::makeTitleSafe( $row->page_namespace, $row->page_title ); if( null == $wgTitle ) { - $this->output( "Page {$row->page_id} bad title\n" ); + $this->output( "Page {$row->page_id} has bad title\n" ); continue; // broken title? } + $wgOut->setTitle( $wgTitle ); // set display title + $wgUser->getSkin( $wgTitle ); // set skin title $wgArticle = new Article( $wgTitle ); // If the article is cacheable, then load it if( $wgArticle->isFileCacheable() ) { -- 2.20.1