mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-03-16 14:40:50 -05:00
Merge pull request #19578 from amcasey/GH19395
Don't pass synthesized node to typeToTypeNode
This commit is contained in:
@@ -730,7 +730,7 @@ namespace ts.refactor.extractSymbol {
|
||||
let type = checker.getTypeOfSymbolAtLocation(usage.symbol, usage.node);
|
||||
// Widen the type so we don't emit nonsense annotations like "function fn(x: 3) {"
|
||||
type = checker.getBaseTypeOfLiteralType(type);
|
||||
typeNode = checker.typeToTypeNode(type, node, NodeBuilderFlags.NoTruncation);
|
||||
typeNode = checker.typeToTypeNode(type, scope, NodeBuilderFlags.NoTruncation);
|
||||
}
|
||||
|
||||
const paramDecl = createParameter(
|
||||
|
||||
Reference in New Issue
Block a user