diff options
Diffstat (limited to 'packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts')
-rw-r--r-- | packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts b/packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts index c1620574f..4dda9cd11 100644 --- a/packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts +++ b/packages/taler-wallet-core/src/crypto/workers/synchronousWorkerNode.ts @@ -174,9 +174,9 @@ export class SynchronousCryptoWorker { * Send a message to the worker thread. */ postMessage(msg: any): void { - const args = msg.args; - if (!Array.isArray(args)) { - console.error("args must be array"); + const req = msg.req; + if (typeof req !== "object") { + console.error("request must be an object"); return; } const id = msg.id; @@ -190,7 +190,7 @@ export class SynchronousCryptoWorker { return; } - this.handleRequest(operation, id, args).catch((e) => { + this.handleRequest(operation, id, req).catch((e) => { console.error("Error while handling crypto request:", e); }); } |