Skip to content

Commit cb4a6fa

Browse files
authored
doc: use same name in the doc as in the code
Refs: https://streams.spec.whatwg.org/#bytelengthqueuingstrategy PR-URL: #49216 Reviewed-By: Antoine du Hamel <[email protected]> Reviewed-By: Deokjin Kim <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 78842cf commit cb4a6fa

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

doc/api/webstreams.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1219,13 +1219,13 @@ changes:
12191219
description: This class is now exposed on the global object.
12201220
-->
12211221
1222-
#### `new ByteLengthQueuingStrategy(options)`
1222+
#### `new ByteLengthQueuingStrategy(init)`
12231223
12241224
<!-- YAML
12251225
added: v16.5.0
12261226
-->
12271227
1228-
* `options` {Object}
1228+
* `init` {Object}
12291229
* `highWaterMark` {number}
12301230
12311231
#### `byteLengthQueuingStrategy.highWaterMark`
@@ -1256,13 +1256,13 @@ changes:
12561256
description: This class is now exposed on the global object.
12571257
-->
12581258
1259-
#### `new CountQueuingStrategy(options)`
1259+
#### `new CountQueuingStrategy(init)`
12601260
12611261
<!-- YAML
12621262
added: v16.5.0
12631263
-->
12641264
1265-
* `options` {Object}
1265+
* `init` {Object}
12661266
* `highWaterMark` {number}
12671267
12681268
#### `countQueuingStrategy.highWaterMark`

lib/internal/webstreams/queuingstrategies.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ class ByteLengthQueuingStrategy {
6969
constructor(init) {
7070
validateObject(init, 'init');
7171
if (init.highWaterMark === undefined)
72-
throw new ERR_MISSING_OPTION('options.highWaterMark');
72+
throw new ERR_MISSING_OPTION('init.highWaterMark');
7373

7474
// The highWaterMark value is not checked until the strategy
7575
// is actually used, per the spec.
@@ -121,7 +121,7 @@ class CountQueuingStrategy {
121121
constructor(init) {
122122
validateObject(init, 'init');
123123
if (init.highWaterMark === undefined)
124-
throw new ERR_MISSING_OPTION('options.highWaterMark');
124+
throw new ERR_MISSING_OPTION('init.highWaterMark');
125125

126126
// The highWaterMark value is not checked until the strategy
127127
// is actually used, per the spec.

0 commit comments

Comments
 (0)