worker: make terminate() resolve for unref’ed Workers
Once `worker.terminate()` is called, the Worker instance will be destroyed as soon as possible anyway, so in order to make the Promise returned by `worker.terminate()` resolve always, it should be okay to just call `.ref()` on it and keep the main event loop alive temporarily. PR-URL: https://github.com/nodejs/node/pull/29484 Reviewed-By:Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com>
parent
d7c5ffc7
Please register or sign in to comment