From: Jérôme Benoit Date: Sat, 16 Sep 2023 21:53:05 +0000 (+0200) Subject: refactor: code cleanup X-Git-Tag: v2.6.45~7 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=9d21ee7f84ab8b3960745f0be0a629a427e101f0;p=poolifier.git refactor: code cleanup Signed-off-by: Jérôme Benoit --- diff --git a/src/pools/abstract-pool.ts b/src/pools/abstract-pool.ts index d3540098..9aa6ec3d 100644 --- a/src/pools/abstract-pool.ts +++ b/src/pools/abstract-pool.ts @@ -699,14 +699,13 @@ export abstract class AbstractPool< (this.opts.tasksQueueOptions?.concurrency as number) ) === -1 ) - } else { - return ( - this.workerNodes.findIndex( - workerNode => - workerNode.info.ready && workerNode.usage.tasks.executing === 0 - ) === -1 - ) } + return ( + this.workerNodes.findIndex( + workerNode => + workerNode.info.ready && workerNode.usage.tasks.executing === 0 + ) === -1 + ) } /** @inheritDoc */