Fix getter of local symbol for export= when it is json module

Fixes #24341
This commit is contained in:
Sheetal Nandi
2018-05-22 17:10:56 -07:00
parent 56f33ad3bb
commit a0d4e4f059
2 changed files with 17 additions and 0 deletions
+3
View File
@@ -579,6 +579,9 @@ namespace ts.FindAllReferences {
else if (isBinaryExpression(decl)) { // `module.exports = class {}`
return Debug.assertDefined(decl.right.symbol);
}
else if (isSourceFile(decl)) { // json module
return Debug.assertDefined(decl.symbol);
}
return Debug.fail();
}