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 74b817b commit 488da14Copy full SHA for 488da14
javascript/extractor/lib/typescript/src/main.ts
@@ -372,7 +372,9 @@ function isExtractableSourceFile(ast: ast_extractor.AugmentedSourceFile): boolea
372
*/
373
function getAstForFile(filename: string): ts.SourceFile {
374
let { ast, code } = parseSingleFile(filename);
375
- ast_extractor.augmentAst(ast, code, null);
+ if (ast != null && isExtractableSourceFile(ast)) {
376
+ ast_extractor.augmentAst(ast, code, null);
377
+ }
378
return ast;
379
}
380
0 commit comments