We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f9123aa commit f2163feCopy full SHA for f2163fe
src/services/codefixes/helpers.ts
@@ -147,7 +147,7 @@ namespace ts.codefix {
147
148
let typeParameters: TypeParameterDeclaration[];
149
if (includeTypeScriptSyntax) {
150
- const typeArgCount = callExpression.typeArguments ? callExpression.typeArguments.length : 0;
+ const typeArgCount = length(callExpression.typeArguments);
151
for (let i = 0; i < typeArgCount; i++) {
152
const name = typeArgCount < 8 ? String.fromCharCode(CharacterCodes.T + i) : `T${i}`;
153
const typeParameter = createTypeParameterDeclaration(name, /*constraint*/ undefined, /*defaultType*/ undefined);
0 commit comments