Code Duplication    Length = 5-6 lines in 2 locations

includes/db/loadbalancer/LoadBalancer.php 2 locations

@@ 352-356 (lines=5) @@
349
		if ( $i !== false ) {
350
			# Slave connection successful
351
			# Wait for the session master pos for a short time
352
			if ( $this->mWaitForPos && $i > 0 ) {
353
				if ( !$this->doWait( $i ) ) {
354
					$this->mServers[$i]['slave pos'] = $conn->getSlavePos();
355
				}
356
			}
357
			if ( $this->mReadIndex <= 0 && $this->mLoads[$i] > 0 && $group === false ) {
358
				$this->mReadIndex = $i;
359
				# Record if the generic reader index is in "lagged slave" mode
@@ 382-387 (lines=6) @@
379
		$this->mWaitForPos = $pos;
380
		$i = $this->mReadIndex;
381
382
		if ( $i > 0 ) {
383
			if ( !$this->doWait( $i ) ) {
384
				$this->mServers[$i]['slave pos'] = $this->getAnyOpenConnection( $i )->getSlavePos();
385
				$this->laggedSlaveMode = true;
386
			}
387
		}
388
	}
389
390
	/**