| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 75fcf53 commit e84e33c
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -298,7 +298,7 @@ too many listeners have been added to an event | |||
| 298 | 298 | ||
| 299 | 299 | ```txt | |
| 300 | 300 | $ node | |
| 301 | - > event.defaultMaxListeners = 1; | ||
| 301 | + > events.defaultMaxListeners = 1; | ||
| 302 | 302 | > process.on('foo', () => {}); | |
| 303 | 303 | > process.on('foo', () => {}); | |
| 304 | 304 | > (node:38638) Warning: Possible EventEmitter memory leak detected. 2 foo | |
@@ -311,7 +311,7 @@ adds a custom handler to the `'warning'` event: | |||
| 311 | 311 | ```txt | |
| 312 | 312 | $ node --no-warnings | |
| 313 | 313 | > var p = process.on('warning', (warning) => console.warn('Do not do that!')); | |
| 314 | - > event.defaultMaxListeners = 1; | ||
| 314 | + > events.defaultMaxListeners = 1; | ||
| 315 | 315 | > process.on('foo', () => {}); | |
| 316 | 316 | > process.on('foo', () => {}); | |
| 317 | 317 | > Do not do that! | |
| Back | FazBrowse Home | New Git URL |
0 commit comments