doc: clarify description of readable.push() method

PR-URL: https://github.com/nodejs/node/pull/29687
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
This commit is contained in:
imhype authored and Rich Trott committed 2019-09-27 15:36:00 -07:00
1 parent 7223ce2a9c
commit 63c0f15a82
1 file changed
+2 -2
+2 -2
View File
@@ -2148,8 +2148,8 @@ class SourceWrapper extends Readable {
}
```
The `readable.push()` method is intended be called only by `Readable`
implementers, and only from within the `readable._read()` method.
The `readable.push()` method is used to push the content
into the internal buffer. It can be driven by the `readable._read()` method.
For streams not operating in object mode, if the `chunk` parameter of
`readable.push()` is `undefined`, it will be treated as empty string or