mirror of
https://github.com/nodejs/node.git
synced 2026-11-21 12:59:16 -05:00
doc: fix typo in cjs example of util.styleText
`errorMessage` needs to be printed instead of `successMessage` in console.error(). ESM example is only fixed in previous PR. Refs: https://github.com/nodejs/node/pull/56720 PR-URL: https://github.com/nodejs/node/pull/56769 Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Jason Zhang <xzha4350@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
1 parent
5557ce4aec
commit
7f18407d0f
1 file changed
+1
-1
+1
-1
@@ -1988,7 +1988,7 @@ const errorMessage = styleText(
|
||||
// Validate if process.stderr has TTY
|
||||
{ stream: stderr },
|
||||
);
|
||||
console.error(successMessage);
|
||||
console.error(errorMessage);
|
||||
```
|
||||
|
||||
`util.inspect.colors` also provides text formats such as `italic`, and
|
||||
|
||||
Reference in new issue
Block a user