Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JS]: False positive "superfluous trailing arguments" for Web Streams API TransformStream constructor with one argument #18249

Open
AlCalzone opened this issue Dec 9, 2024 · 0 comments

Comments

@AlCalzone
Copy link

Description of the false positive

When calling super in a subclass of TransformStream with a transformer as an argument, CodeQL complains about superfluous trailing arguments.

The TransformStream constructor can take multiple arguments, so this report isn't valid.

Code samples or links to source code

https://github.com/zwave-js/node-zwave-js/blob/6b52a22591a0f11628751b2b53a88d5d89f66b6f/packages/serial/src/parsers/BootloaderParsers.ts#L81-L89

export class BootloaderScreenParser extends TransformStream<Uint8Array, number | string>
{
	constructor() {
		super(new BootloaderScreenParserTransformer());
		// BootloaderScreenParserTransformer implements Transformer<Uint8Array, number | string>
	}
}

URL to the alert on GitHub code scanning (optional)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant