mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-08-17 00:18:41 -07:00
12 lines
457 B
TypeScript
12 lines
457 B
TypeScript
import { parentPort, workerData } from 'node:worker_threads';
|
|
import { executeLexicalRollupBackfillTask } from './lexical-rollup-worker';
|
|
|
|
if (!parentPort) throw new Error('lexical rollup worker missing parent port');
|
|
|
|
try {
|
|
executeLexicalRollupBackfillTask((workerData as { dbPath: string }).dbPath);
|
|
parentPort.postMessage({ ok: true });
|
|
} catch (error) {
|
|
parentPort.postMessage({ error: error instanceof Error ? error.message : String(error) });
|
|
}
|