From 5b221d1891016609a2ed28069fcfa4eea9ff1868 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 10 Jun 2026 04:12:08 +0000 Subject: [PATCH] docs: add missing `@throws` tags to `@stdlib/streams/node/split` constructor Added two `@throws {TypeError}` JSDoc tags to the `SplitStream` constructor in `lib/main.js`. The constructor invokes `validate( opts, options )` and rethrows the returned `TypeError` when `options` is not a plain object or when an individual option fails validation, but the JSDoc previously documented neither failure mode. The added tags match the wording already present in the package's own `lib/object_mode.js` and `lib/factory.js`, and bring the constructor into line with the 12 sibling constructors in `@stdlib/streams/node` that share the validate-then-throw pattern (100% conformance among factory siblings). --- lib/node_modules/@stdlib/streams/node/split/lib/main.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/node_modules/@stdlib/streams/node/split/lib/main.js b/lib/node_modules/@stdlib/streams/node/split/lib/main.js index ea0800d2f7c2..5212fc4fb947 100644 --- a/lib/node_modules/@stdlib/streams/node/split/lib/main.js +++ b/lib/node_modules/@stdlib/streams/node/split/lib/main.js @@ -172,6 +172,8 @@ function destroy( error ) { * @param {NonNegativeNumber} [options.highWaterMark] - specifies the `Buffer` level for when `write()` starts returning `false` * @param {boolean} [options.allowHalfOpen=false] - specifies whether the stream should remain open even if one side ends * @param {boolean} [options.writableObjectMode=false] - specifies whether the writable side should be in object mode +* @throws {TypeError} options argument must be an object +* @throws {TypeError} must provide valid options * @returns {SplitStream} split stream * * @example