Skip to content

fix: Leverage new web-worker dep to close workers cross-platform#21

Merged
jbaylina merged 1 commit into
iden3:masterfrom
phated:phated/webworker-close
Nov 17, 2021
Merged

fix: Leverage new web-worker dep to close workers cross-platform#21
jbaylina merged 1 commit into
iden3:masterfrom
phated:phated/webworker-close

Conversation

@phated

@phated phated commented Nov 5, 2021

Copy link
Copy Markdown
Contributor

I was digging into the usage of process.exit() to close the worker and found that it only works inside nodejs. However, the WebWorker spec provides requires a self.close() in a Worker's global scope (docs at https://developer.mozilla.org/en-US/docs/Web/API/DedicatedWorkerGlobalScope/close)

So I upstreamed a fix to the web-worker dependency at developit/web-worker#21 and now we can use a cross-platform self.close() to terminate the workers!

@jbaylina
jbaylina merged commit fc31d7d into iden3:master Nov 17, 2021
@phated
phated deleted the phated/webworker-close branch November 17, 2021 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants