Skip to content

Commit

Permalink
doc: fix function name in process.md
Browse files Browse the repository at this point in the history
setUncaughtExceptionCapture -> setUncaughtExceptionCaptureCallback

process.setUncaughtExceptionCaptureCallback and its docs were originally
added in #17159

PR-URL: #21523
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
  • Loading branch information
Joonas Rouhiainen authored and vsemozhetbyt committed Jun 27, 2018
1 parent 449f73b commit 1f6adff
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions doc/api/process.md
Original file line number Diff line number Diff line change
Expand Up @@ -1720,18 +1720,19 @@ added: v9.3.0

* `fn` {Function|null}

The `process.setUncaughtExceptionCapture` function sets a function that will
be invoked when an uncaught exception occurs, which will receive the exception
value itself as its first argument.
The `process.setUncaughtExceptionCaptureCallback()` function sets a function
that will be invoked when an uncaught exception occurs, which will receive the
exception value itself as its first argument.

If such a function is set, the [`'uncaughtException'`][] event will
not be emitted. If `--abort-on-uncaught-exception` was passed from the
command line or set through [`v8.setFlagsFromString()`][], the process will
not abort.

To unset the capture function, `process.setUncaughtExceptionCapture(null)`
may be used. Calling this method with a non-`null` argument while another
capture function is set will throw an error.
To unset the capture function,
`process.setUncaughtExceptionCaptureCallback(null)` may be used. Calling this
method with a non-`null` argument while another capture function is set will
throw an error.

Using this function is mutually exclusive with using the deprecated
[`domain`][] built-in module.
Expand Down

0 comments on commit 1f6adff

Please sign in to comment.