Skip to content
This repository has been archived by the owner on Jul 15, 2024. It is now read-only.

Commit

Permalink
fixProcessBootstrapper): handle error
Browse files Browse the repository at this point in the history
Co-authored-by: KagChi <[email protected]>
Co-authored-by: Vann <[email protected]>
  • Loading branch information
3 people authored Feb 20, 2024
1 parent a02d9ea commit 46a7f49
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,15 @@ export class ProcessContextFetchingStrategy implements IContextFetchingStrategy
}

const listener = (): void => {
process.send!({
const message = {
op: WorkerReceivePayloadOp.CancelIdentify,
nonce
});
};
try {
process.send!(message);
} catch {
setTimeout(async () => Result.fromAsync(() => process.send!(message)), 2_000);
}
};

(signal as unknown as PolyFillAbortSignal).addEventListener("abort", listener);
Expand Down

0 comments on commit 46a7f49

Please sign in to comment.