From: Sam Reed Date: Mon, 11 Apr 2011 18:37:29 +0000 (+0000) Subject: Revert r85799 X-Git-Tag: 1.31.0-rc.0~30928 X-Git-Url: http://git.cyclocoop.org/%22.%28%24lien.?a=commitdiff_plain;h=1fcb3715ccbaf4efe986ab6edbdc51e12a826437;p=lhc%2Fweb%2Fwiklou.git Revert r85799 --- diff --git a/includes/LinksUpdate.php b/includes/LinksUpdate.php index c0bf543110..a800fdfa07 100644 --- a/includes/LinksUpdate.php +++ b/includes/LinksUpdate.php @@ -345,22 +345,15 @@ class LinksUpdate { $where = false; } } - - // Create and use a new loadBalancer object, to prevent "1205: Lock wait timeout exceeded;" - $lb = wfGetLBFactory()->newMainLB(); - $dbw = $lb->getConnection( DB_MASTER ); - if ( $where ) { - $dbw->delete( $table, $where, __METHOD__ ); + $this->mDb->delete( $table, $where, __METHOD__ ); } if ( count( $insertions ) ) { - $dbw->insert( $table, $insertions, __METHOD__, 'IGNORE' ); + $this->mDb->insert( $table, $insertions, __METHOD__, 'IGNORE' ); } - - $lb->commitMasterChanges(); - $lb->closeAll(); } + /** * Get an array of pagelinks insertions for passing to the DB * Skips the titles specified by the 2-D array $existing