From: Chris Duncan Date: Fri, 19 Jun 2026 06:24:57 +0000 (-0700) Subject: Queue async retry faster while waiting for Node host. X-Git-Tag: v1.0.4~4 X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=2abf01f31d5b9fae08851c2361f5d791ae97e693;p=nano25519.git Queue async retry faster while waiting for Node host. --- diff --git a/src/lib/nano25519.ts b/src/lib/nano25519.ts index 373f136..9df7e5b 100644 --- a/src/lib/nano25519.ts +++ b/src/lib/nano25519.ts @@ -189,7 +189,7 @@ const nano25519_init = (bytes: number[]): { derive: typeof derive, sign: typeof * @param {object} message.data - Worker commands and related data */ function handleMessage (message: unknown): void { - NODE: if (host == null) setTimeout(() => handleMessage(message), 0) + NODE: if (host == null) return queueMicrotask(() => handleMessage(message)) let result: undefined | boolean | string | Uint8Array let url: undefined | string let id: undefined | string