X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fworker%2Fthread-worker.ts;fp=src%2Fworker%2Fthread-worker.ts;h=7115d71568a6fc0664ba6f74b17085b35bc50655;hb=ded253e27e59ae936fe91d789d8454b7eb11dd6a;hp=638de2ba2f9c8f090360c528cd1169cfcd52e823;hpb=0e8691794db51210b4bcc6af77d54326583a269a;p=poolifier.git diff --git a/src/worker/thread-worker.ts b/src/worker/thread-worker.ts index 638de2ba..7115d715 100644 --- a/src/worker/thread-worker.ts +++ b/src/worker/thread-worker.ts @@ -1,13 +1,14 @@ import { - type MessagePort, isMainThread, + type MessagePort, parentPort, threadId } from 'node:worker_threads' + import type { MessageValue } from '../utility-types.js' import { AbstractWorker } from './abstract-worker.js' -import type { WorkerOptions } from './worker-options.js' import type { TaskFunction, TaskFunctions } from './task-functions.js' +import type { WorkerOptions } from './worker-options.js' /** * A thread worker used by a poolifier `ThreadPool`.