remove any annotation from declare method quickfix

This commit is contained in:
Joseph Wunderlich
2019-02-22 17:24:21 -08:00
parent 999eb0b9ed
commit 21ab39649c
11 changed files with 59 additions and 26 deletions
+1 -1
View File
@@ -156,7 +156,7 @@ namespace ts.codefix {
isIdentifier(arg) ? arg.text :
isPropertyAccessExpression(arg) ? arg.name.text : undefined);
const contextualType = checker.getContextualType(call);
const returnType = inJs ? undefined : contextualType && checker.typeToTypeNode(contextualType, contextNode, /*flags*/ undefined, tracker) || createKeywordTypeNode(SyntaxKind.AnyKeyword);
const returnType = inJs ? undefined : contextualType && checker.typeToTypeNode(contextualType, contextNode, /*flags*/ undefined, tracker);
return createMethod(
/*decorators*/ undefined,
/*modifiers*/ makeStatic ? [createToken(SyntaxKind.StaticKeyword)] : undefined,