Skip to content

Commit 61709ce

Browse files
committed
doc: revert incorrect change on readable._read
nodejs#17979 introduced a change in the doc that was not correct about _read always being called asynchronously. This does not hold true when it is in flowing mode. See: nodejs#17979 Fixes: nodejs#24919
1 parent 4c9ea8f commit 61709ce

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

Diff for: doc/api/stream.md

+1-7
Original file line numberDiff line numberDiff line change
@@ -1846,10 +1846,6 @@ const myReadable = new Readable({
18461846
#### readable.\_read(size)
18471847
<!-- YAML
18481848
added: v0.9.4
1849-
changes:
1850-
- version: v10.0.0
1851-
pr-url: https://github.com/nodejs/node/pull/17979
1852-
description: Call `_read()` only once per microtick.
18531849
-->
18541850

18551851
* `size` {number} Number of bytes to read asynchronously
@@ -1869,9 +1865,7 @@ when `_read()` is called again after it has stopped should it resume pushing
18691865
additional data onto the queue.
18701866

18711867
Once the `readable._read()` method has been called, it will not be called again
1872-
until the [`readable.push()`][stream-push] method is called. `readable._read()`
1873-
is guaranteed to be called only once within a synchronous execution, i.e. a
1874-
microtick.
1868+
until the [`readable.push()`][stream-push] method is called.
18751869

18761870
The `size` argument is advisory. For implementations where a "read" is a
18771871
single operation that returns data can use the `size` argument to determine how

0 commit comments

Comments
 (0)