| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 1125e10 commit 1beb169
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -440,10 +440,12 @@ occurs, the `callback` *may or may not* be called with the error as its | |||
| 440 | 440 | first argument. To reliably detect write errors, add a listener for the | |
| 441 | 441 | `'error'` event. | |
| 442 | 442 | ||
| 443 | - The return value indicates whether the written `chunk` was buffered internally | ||
| 444 | - and the buffer has exceeded the `highWaterMark` configured when the stream was | ||
| 445 | - created. If `false` is returned, further attempts to write data to the stream | ||
| 446 | - should be paused until the [`'drain'`][] event is emitted. | ||
| 443 | + The return value is `true` if the internal buffer does not exceed | ||
| 444 | + `highWaterMark` configured when the stream was created after admitting `chunk`. | ||
| 445 | + If `false` is returned, further attempts to write data to the stream should | ||
| 446 | + stop until the [`'drain'`][] event is emitted. However, the `false` return | ||
| 447 | + value is only advisory and the writable stream will unconditionally accept and | ||
| 448 | + buffer `chunk` even if it has not not been allowed to drain. | ||
| 447 | 449 | ||
| 448 | 450 | A Writable stream in object mode will always ignore the `encoding` argument. | |
| 449 | 451 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments