Skip to content

Commit 13ecff6

Browse files
glasserruyadorno
authored andcommitted
src: document newer values for --unhandled-rejections flag
These values were added in v15.0.0 by #33475 but were not included in the `node --help` output. Also documents which value is the default. PR-URL: #37899 Fixes: #37896 Refs: #33475 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent d44b268 commit 13ecff6

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/node_options.cc

+6-2
Original file line numberDiff line numberDiff line change
@@ -500,8 +500,12 @@ EnvironmentOptionsParser::EnvironmentOptionsParser() {
500500
&EnvironmentOptions::trace_warnings,
501501
kAllowedInEnvironment);
502502
AddOption("--unhandled-rejections",
503-
"define unhandled rejections behavior. Options are 'strict' (raise "
504-
"an error), 'warn' (enforce warnings) or 'none' (silence warnings)",
503+
"define unhandled rejections behavior. Options are 'strict' "
504+
"(always raise an error), 'throw' (raise an error unless "
505+
"'unhandledRejection' hook is set), 'warn' (log a warning), 'none' "
506+
"(silence warnings), 'warn-with-error-code' (log a warning and set "
507+
"exit code 1 unless 'unhandledRejection' hook is set). (default: "
508+
"throw)",
505509
&EnvironmentOptions::unhandled_rejections,
506510
kAllowedInEnvironment);
507511
AddOption("--verify-base-objects",

0 commit comments

Comments
 (0)