build(deps-dev): apply updates
[poolifier.git] / src / worker / cluster-worker.ts
index fa810c7e66451ba978320ab887c8073c74214a88..eedf13bd9265cb30b6d7cd689c42e2c517367acd 100644 (file)
@@ -32,7 +32,7 @@ export class ClusterWorker<
     taskFunctions: TaskFunction<Data, Response> | TaskFunctions<Data, Response>,
     opts: WorkerOptions = {}
   ) {
-    super(cluster.isPrimary, cluster.worker as Worker, taskFunctions, opts)
+    super(cluster.isPrimary, cluster.worker, taskFunctions, opts)
   }
 
   /** @inheritDoc */
@@ -62,6 +62,9 @@ export class ClusterWorker<
   protected readonly sendToMainWorker = (
     message: MessageValue<Response>
   ): void => {
-    this.getMainWorker().send({ ...message, workerId: this.id })
+    this.getMainWorker().send({
+      ...message,
+      workerId: this.id
+    } satisfies MessageValue<Response>)
   }
 }