doc: fix example description for worker_threads

PR-URL: https://github.com/nodejs/node/pull/41341
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
This commit is contained in:
Dmitry Petrov authored and Michaël Zasso committed 2022-01-14 16:19:44 +01:00
1 parent ffe17a84f2
commit c267bb2192
1 file changed
+1 -1
+1 -1
View File
@@ -47,7 +47,7 @@ if (isMainThread) {
}
```
The above example spawns a Worker thread for each `parse()` call. In actual
The above example spawns a Worker thread for each `parseJSAsync()` call. In
practice, use a pool of Workers for these kinds of tasks. Otherwise, the
overhead of creating Workers would likely exceed their benefit.