File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed
javascript/ql/lib/semmle/javascript Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -273,10 +273,21 @@ module AccessPath {
273273 root .isGlobal ( )
274274 )
275275 or
276- exists ( Closure:: ClosureModule mod |
276+ exists ( Closure:: ClosureModule mod | root . isGlobal ( ) |
277277 node = mod .getExportsVariable ( ) .getAnAssignedExpr ( ) .flow ( ) and
278- root .isGlobal ( ) and
279278 result = mod .getClosureNamespace ( )
279+ 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+ or
286+ exists ( ExportDefaultDeclaration decl |
287+ decl .getContainer ( ) = mod and
288+ node = DataFlow:: valueNode ( decl .getOperand ( ) ) and
289+ result = mod .getClosureNamespace ( )
290+ )
280291 )
281292 }
282293
You can’t perform that action at this time.
0 commit comments