Skip to content

Commit 820875f

Browse files
committed
doc: update writable.write return value
Fix the explanation which stated that write() would return false if highWaterMark is exceeded to correctly state that false is returned once highWaterMark is reached. See nodejs#9247.
1 parent ff1efa6 commit 820875f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

doc/api/stream.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ occurs, the `callback` *may or may not* be called with the error as its
440440
first argument. To reliably detect write errors, add a listener for the
441441
`'error'` event.
442442

443-
The return value is `true` if the internal buffer does not exceed
443+
The return value is `true` if the internal buffer is less than the
444444
`highWaterMark` configured when the stream was created after admitting `chunk`.
445445
If `false` is returned, further attempts to write data to the stream should
446446
stop until the [`'drain'`][] event is emitted. However, the `false` return

0 commit comments

Comments
 (0)