Add option to populateChangeTagDef not to update the count
[lhc/web/wiklou.git] / maintenance / storage / recompressTracked.php
index 49b8e0a..7f36442 100644 (file)
@@ -24,6 +24,7 @@
 
 use MediaWiki\Logger\LegacyLogger;
 use MediaWiki\MediaWikiServices;
+use Wikimedia\Rdbms\IDatabase;
 
 $optionsWithArgs = RecompressTracked::getOptionsWithArgs();
 require __DIR__ . '/../commandLine.inc';
@@ -226,7 +227,7 @@ class RecompressTracked {
                }
                $cmd .= ' --child' .
                        ' --wiki ' . wfEscapeShellArg( wfWikiID() ) .
-                       ' ' . call_user_func_array( 'wfEscapeShellArg', $this->destClusters );
+                       ' ' . wfEscapeShellArg( ...$this->destClusters );
 
                $this->replicaPipes = $this->replicaProcs = [];
                for ( $i = 0; $i < $this->numProcs; $i++ ) {
@@ -426,12 +427,12 @@ class RecompressTracked {
                                $args = array_slice( $ids, 0, $this->orphanBatchSize );
                                $ids = array_slice( $ids, $this->orphanBatchSize );
                                array_unshift( $args, 'doOrphanList' );
-                               call_user_func_array( [ $this, 'dispatch' ], $args );
+                               $this->dispatch( ...$args );
                        }
                        if ( count( $ids ) ) {
                                $args = $ids;
                                array_unshift( $args, 'doOrphanList' );
-                               call_user_func_array( [ $this, 'dispatch' ], $args );
+                               $this->dispatch( ...$args );
                        }
 
                        $this->report( 'orphans', $i, $numOrphans );
@@ -640,7 +641,7 @@ class RecompressTracked {
        /**
         * Gets a DB master connection for the given external cluster name
         * @param string $cluster
-        * @return Database
+        * @return IDatabase
         */
        function getExtDB( $cluster ) {
                $lbFactory = MediaWikiServices::getInstance()->getDBLoadBalancerFactory();