From: Jérôme Benoit Date: Mon, 26 Sep 2022 07:26:15 +0000 (+0200) Subject: Cleanup X-Git-Tag: v2.2.1~36 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=dd043cd30c05a8166bdab4f9665cc34427c2a33b;p=poolifier.git Cleanup Signed-off-by: Jérôme Benoit --- diff --git a/src/pools/selection-strategies.ts b/src/pools/selection-strategies.ts index 034b1612..20e02f31 100644 --- a/src/pools/selection-strategies.ts +++ b/src/pools/selection-strategies.ts @@ -60,7 +60,7 @@ class RoundRobinWorkerChoiceStrategy public choose (): Worker { const chosenWorker = this.pool.workers[this.nextWorkerIndex] this.nextWorkerIndex = - this.pool.workers.length - 1 === this.nextWorkerIndex + this.nextWorkerIndex === this.pool.workers.length - 1 ? 0 : this.nextWorkerIndex + 1 return chosenWorker