build: silence code smells
authorJérôme Benoit <jerome.benoit@sap.com>
Tue, 18 Apr 2023 18:49:08 +0000 (20:49 +0200)
committerJérôme Benoit <jerome.benoit@sap.com>
Tue, 18 Apr 2023 18:49:08 +0000 (20:49 +0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
src/pools/abstract-pool.ts

index b299bc0172e839fdc57e165bd8e1391200a17885..473789809d2dde4ea57571dd1a2ded5dd7499477 100644 (file)
@@ -7,13 +7,13 @@ import {
 } from '../utils'
 import { KillBehaviors, isKillBehavior } from '../worker/worker-options'
 import {
+  PoolEmitter,
   PoolEvents,
   type IPool,
   type PoolOptions,
   type TasksQueueOptions,
   PoolType
 } from './pool'
-import { PoolEmitter } from './pool'
 import type { IWorker, Task, TasksUsage, WorkerNode } from './worker'
 import {
   WorkerChoiceStrategies,
@@ -428,7 +428,7 @@ export abstract class AbstractPool<
         ) {
           // Kill message received from the worker: no new tasks are submitted to that worker for a while ( > maxInactiveTime)
           this.flushTasksQueueByWorker(workerCreated)
-          void this.destroyWorker(workerCreated)
+          void (this.destroyWorker(workerCreated) as Promise<void>)
         }
       })
       workerNodeKey = this.getWorkerNodeKey(workerCreated)