refactor: cleanup worker choice strategy options handling
[poolifier.git] / src / pools / selection-strategies / abstract-worker-choice-strategy.ts
index 476c58bc8bcf45f69450adb196e8886abe6f3b88..121647b697139e9c068170d266d96f2c0837edad 100644 (file)
@@ -133,9 +133,8 @@ export abstract class AbstractWorkerChoiceStrategy<
 
   /** @inheritDoc */
   public setOptions (opts: WorkerChoiceStrategyOptions): void {
-    opts = opts ?? DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS
-    this.setTaskStatisticsRequirements(opts)
-    this.opts = opts
+    this.opts = opts ?? DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS
+    this.setTaskStatisticsRequirements(this.opts)
   }
 
   // /**