mirror of
https://github.com/github/codeql.git
synced 2026-05-10 17:29:26 +02:00
TS: fix analysis of export= statements
This commit is contained in:
@@ -156,7 +156,12 @@ private class AnalyzedImport extends AnalyzedPropertyRead, DataFlow::ValueNode {
|
||||
or
|
||||
// when importing CommonJS/AMD modules from ES2015, `module.exports` appears
|
||||
// as the default export
|
||||
not imported instanceof ES2015Module and
|
||||
(
|
||||
not imported instanceof ES2015Module
|
||||
or
|
||||
// CommonJS/AMD module generated by TypeScript compiler
|
||||
imported.getAStmt() instanceof ExportAssignDeclaration
|
||||
) and
|
||||
astNode.(ImportSpecifier).getImportedName() = "default" and
|
||||
base = TAbstractModuleObject(imported) and
|
||||
propName = "exports"
|
||||
|
||||
Reference in New Issue
Block a user