Merge "Fix documentation of Maintenance::updateSearchIndex"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Mon, 10 Jun 2019 20:18:53 +0000 (20:18 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Mon, 10 Jun 2019 20:18:53 +0000 (20:18 +0000)
1  2 
maintenance/Maintenance.php

@@@ -26,6 -26,7 +26,7 @@@ require_once __DIR__ . '/../includes/PH
  wfEntryPointCheck( 'text' );
  
  use MediaWiki\Shell\Shell;
+ use Wikimedia\Rdbms\IResultWrapper;
  
  /**
   * @defgroup MaintenanceArchive Maintenance archives
@@@ -1478,9 -1479,9 +1479,9 @@@ abstract class Maintenance 
        /**
         * Perform a search index update with locking
         * @param int $maxLockTime The maximum time to keep the search index locked.
-        * @param string $callback The function that will update the function.
+        * @param callable $callback The function that will update the function.
         * @param IMaintainableDatabase $dbw
-        * @param array $results
+        * @param array|IResultWrapper $results
         */
        public function updateSearchIndex( $maxLockTime, $callback, $dbw, $results ) {
                $lockTime = time();
@@@ -1724,7 -1725,7 +1725,7 @@@ abstract class LoggedUpdateMaintenance 
                        return false;
                }
  
 -              $db->insert( 'updatelog', [ 'ul_key' => $key ], __METHOD__, 'IGNORE' );
 +              $db->insert( 'updatelog', [ 'ul_key' => $key ], __METHOD__, [ 'IGNORE' ] );
  
                return true;
        }