Skip to content

Commit

Permalink
doc: fix a typo in api/process.md
Browse files Browse the repository at this point in the history
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 <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
  • Loading branch information
sabakugaara authored and MylesBorins committed Apr 18, 2017
1 parent 6d61296 commit 12772b0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/api/process.md
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ too many listeners have been added to an event

```txt
$ node
> event.defaultMaxListeners = 1;
> events.defaultMaxListeners = 1;
> process.on('foo', () => {});
> process.on('foo', () => {});
> (node:38638) Warning: Possible EventEmitter memory leak detected. 2 foo
Expand All @@ -303,7 +303,7 @@ adds a custom handler to the `'warning'` event:
```txt
$ node --no-warnings
> var p = process.on('warning', (warning) => console.warn('Do not do that!'));
> event.defaultMaxListeners = 1;
> events.defaultMaxListeners = 1;
> process.on('foo', () => {});
> process.on('foo', () => {});
> Do not do that!
Expand Down

0 comments on commit 12772b0

Please sign in to comment.