Skip to content

Commit e84e33c

Browse files
sabakugaaraitaloacasas
authored andcommitted
doc: fix a typo in api/process.md
Fix a mistyped module name in example REPL sessions found in the description of the 'warning' event: it should be `events` instead of `event`. PR-URL: #11780 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent 75fcf53 commit e84e33c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/api/process.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ too many listeners have been added to an event
298298

299299
```txt
300300
$ node
301-
> event.defaultMaxListeners = 1;
301+
> events.defaultMaxListeners = 1;
302302
> process.on('foo', () => {});
303303
> process.on('foo', () => {});
304304
> (node:38638) Warning: Possible EventEmitter memory leak detected. 2 foo
@@ -311,7 +311,7 @@ adds a custom handler to the `'warning'` event:
311311
```txt
312312
$ node --no-warnings
313313
> var p = process.on('warning', (warning) => console.warn('Do not do that!'));
314-
> event.defaultMaxListeners = 1;
314+
> events.defaultMaxListeners = 1;
315315
> process.on('foo', () => {});
316316
> process.on('foo', () => {});
317317
> Do not do that!

0 commit comments

Comments
 (0)