We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 31aebc7 commit 01b1e8aCopy full SHA for 01b1e8a
1 file changed
javascript/ql/lib/semmle/javascript/GlobalAccessPaths.qll
@@ -273,10 +273,21 @@ module AccessPath {
273
root.isGlobal()
274
)
275
or
276
- exists(Closure::ClosureModule mod |
+ exists(Closure::ClosureModule mod | root.isGlobal() |
277
node = mod.getExportsVariable().getAnAssignedExpr().flow() and
278
- root.isGlobal() and
279
result = mod.getClosureNamespace()
+ or
280
+ exists(ExportNamedDeclaration decl, string name |
281
+ decl.getContainer() = mod and
282
+ node = decl.getSourceNode(name) and
283
+ result = join(mod.getClosureNamespace(), name)
284
+ )
285
286
+ exists(ExportDefaultDeclaration decl |
287
288
+ node = DataFlow::valueNode(decl.getOperand()) and
289
+ result = mod.getClosureNamespace()
290
291
292
}
293
0 commit comments