$wgArticle is deprecated! Possible removal in 1.20 or 1.21!
[lhc/web/wiklou.git] / maintenance / rebuildFileCache.php
index 01b7b1f..aa1bbbb 100644 (file)
@@ -31,9 +31,12 @@ class RebuildFileCache extends Maintenance {
                $this->setBatchSize( 100 );
        }
 
+       /**
+        * @todo MAKE $wgArticle GO AWAY! This is the absolute LAST use in core
+        */
        public function execute() {
                global $wgUseFileCache, $wgDisableCounters, $wgContentNamespaces, $wgRequestTime;
-               global $wgTitle, $wgArticle, $wgOut, $wgUser;
+               global $wgTitle, $wgArticle, $wgOut;
                if ( !$wgUseFileCache ) {
                        $this->error( "Nothing to do -- \$wgUseFileCache is disabled.", true );
                }
@@ -80,7 +83,6 @@ class RebuildFileCache extends Maintenance {
                                        continue; // broken title?
                                }
                                $wgOut = $context->output; // set display title
-                               $wgUser->getSkin( $wgTitle ); // set skin title
                                $wgArticle = new Article( $wgTitle );
                                // If the article is cacheable, then load it
                                if ( $wgArticle->isFileCacheable() ) {
@@ -110,7 +112,7 @@ class RebuildFileCache extends Maintenance {
                        }
                        $blockStart += $this->mBatchSize;
                        $blockEnd += $this->mBatchSize;
-                       wfWaitForSlaves( 5 );
+                       wfWaitForSlaves();
                }
                $this->output( "Done!\n" );