mirror of
https://github.com/github/codeql.git
synced 2026-04-22 07:15:15 +02:00
JS: Restrict type-only exports in API graphs
This commit is contained in:
@@ -1635,6 +1635,7 @@ private predicate exports(string m, DataFlow::Node rhs) {
|
||||
/** Holds if module `m` exports `rhs` under the name `prop`. */
|
||||
private predicate exports(string m, string prop, DataFlow::Node rhs) {
|
||||
exists(ExportDeclaration exp | exp.getEnclosingModule() = importableModule(m) |
|
||||
not exp.isTypeOnly() and
|
||||
rhs = exp.getSourceNode(prop)
|
||||
or
|
||||
exists(Variable v |
|
||||
|
||||
Reference in New Issue
Block a user