Skip to content

Commit 5ae2b74

Browse files
SaleemMylesBorins
authored andcommitted
doc: use consistent naming in stream doc
Consistency of method naming referred to as readable.push several other times in transform documentation and also documented under readable, so makes sense to just stick with readable.push PR-URL: #30506 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent a0cfa62 commit 5ae2b74

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

doc/api/stream.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2648,7 +2648,7 @@ method. This will be called when there is no more written data to be consumed,
26482648
but before the [`'end'`][] event is emitted signaling the end of the
26492649
[`Readable`][] stream.
26502650

2651-
Within the `transform._flush()` implementation, the `readable.push()` method
2651+
Within the `transform._flush()` implementation, the `transform.push()` method
26522652
may be called zero or more times, as appropriate. The `callback` function must
26532653
be called when the flush operation is complete.
26542654

@@ -2677,7 +2677,7 @@ methods only.
26772677
All `Transform` stream implementations must provide a `_transform()`
26782678
method to accept input and produce output. The `transform._transform()`
26792679
implementation handles the bytes being written, computes an output, then passes
2680-
that output off to the readable portion using the `readable.push()` method.
2680+
that output off to the readable portion using the `transform.push()` method.
26812681

26822682
The `transform.push()` method may be called zero or more times to generate
26832683
output from a single input chunk, depending on how much is to be output
@@ -2689,7 +2689,7 @@ The `callback` function must be called only when the current chunk is completely
26892689
consumed. The first argument passed to the `callback` must be an `Error` object
26902690
if an error occurred while processing the input or `null` otherwise. If a second
26912691
argument is passed to the `callback`, it will be forwarded on to the
2692-
`readable.push()` method. In other words, the following are equivalent:
2692+
`transform.push()` method. In other words, the following are equivalent:
26932693

26942694
```js
26952695
transform.prototype._transform = function(data, encoding, callback) {

0 commit comments

Comments
 (0)