From: Aaron Schulz Date: Fri, 4 Mar 2016 19:33:52 +0000 (-0800) Subject: Fix some JobQueue IDEA errors X-Git-Tag: 1.31.0-rc.0~7719^2 X-Git-Url: http://git.cyclocoop.org/wiki/Target_page?a=commitdiff_plain;h=b5d8f3aed16e7d9ab5e7f7a480a274db6e1e9c04;p=lhc%2Fweb%2Fwiklou.git Fix some JobQueue IDEA errors Change-Id: I624f65ee1ca97c1acae9b54ca36d910eb4e42a70 --- diff --git a/includes/jobqueue/JobQueueDB.php b/includes/jobqueue/JobQueueDB.php index aaf9fb048d..479ec3289c 100644 --- a/includes/jobqueue/JobQueueDB.php +++ b/includes/jobqueue/JobQueueDB.php @@ -452,7 +452,6 @@ class JobQueueDB extends JobQueue { * @see JobQueue::doAck() * @param Job $job * @throws MWException - * @return Job|bool */ protected function doAck( Job $job ) { if ( !isset( $job->metadata['id'] ) ) { @@ -476,8 +475,6 @@ class JobQueueDB extends JobQueue { } catch ( DBError $e ) { $this->throwDBException( $e ); } - - return true; } /** diff --git a/includes/jobqueue/JobQueueFederated.php b/includes/jobqueue/JobQueueFederated.php index c127239360..bd832dbcd6 100644 --- a/includes/jobqueue/JobQueueFederated.php +++ b/includes/jobqueue/JobQueueFederated.php @@ -49,7 +49,7 @@ class JobQueueFederated extends JobQueue { /** @var HashRing */ protected $partitionRing; - /** @var array (partition name => JobQueue) reverse sorted by weight */ + /** @var JobQueue[] (partition name => JobQueue) reverse sorted by weight */ protected $partitionQueues = []; /** @var int Maximum number of partitions to try */ @@ -311,7 +311,7 @@ class JobQueueFederated extends JobQueue { throw new MWException( "The given job has no defined partition name." ); } - return $this->partitionQueues[$job->metadata['QueuePartition']]->ack( $job ); + $this->partitionQueues[$job->metadata['QueuePartition']]->ack( $job ); } protected function doIsRootJobOldDuplicate( Job $job ) {