Merge "Add @var annotations to XmlTypeCheck class"
[lhc/web/wiklou.git] / includes / deferred / LinksUpdate.php
index 14f86b7..266d768 100644 (file)
@@ -497,7 +497,7 @@ class LinksUpdate extends DataUpdate implements EnqueueableDataUpdate {
 
                $insertBatches = array_chunk( $insertions, $bSize );
                foreach ( $insertBatches as $insertBatch ) {
-                       $this->getDB()->insert( $table, $insertBatch, __METHOD__, 'IGNORE' );
+                       $this->getDB()->insert( $table, $insertBatch, __METHOD__, [ 'IGNORE' ] );
                        $lbf->commitAndWaitForReplication(
                                __METHOD__, $this->ticket, [ 'domain' => $domainId ]
                        );
@@ -615,7 +615,8 @@ class LinksUpdate extends DataUpdate implements EnqueueableDataUpdate {
                        $nt = Title::makeTitleSafe( NS_CATEGORY, $name );
                        $contLang->findVariantLink( $name, $nt, true );
 
-                       $type = MWNamespace::getCategoryLinkType( $this->mTitle->getNamespace() );
+                       $type = MediaWikiServices::getInstance()->getNamespaceInfo()->
+                               getCategoryLinkType( $this->mTitle->getNamespace() );
 
                        # Treat custom sortkeys as a prefix, so that if multiple
                        # things are forced to sort as '*' or something, they'll
@@ -964,7 +965,7 @@ class LinksUpdate extends DataUpdate implements EnqueueableDataUpdate {
 
        /**
         * Get an array of existing inline interwiki links, as a 2-D array
-        * @return array (prefix => array(dbkey => 1))
+        * @return array [ prefix => [ dbkey => 1 ] ]
         */
        private function getExistingInterwikis() {
                $res = $this->getDB()->select( 'iwlinks', [ 'iwl_prefix', 'iwl_title' ],