diff --git a/javascript/ql/lib/semmle/javascript/ApiGraphs.qll b/javascript/ql/lib/semmle/javascript/ApiGraphs.qll index 8e8881b8950..45efee5f3c0 100644 --- a/javascript/ql/lib/semmle/javascript/ApiGraphs.qll +++ b/javascript/ql/lib/semmle/javascript/ApiGraphs.qll @@ -2164,6 +2164,10 @@ private predicate isDeclaredPackageName(string m) { overlay[local] private predicate isImportedPackageName(string m) { - m = any(Import imprt).getImportedPathString() and + ( + m = any(Import imprt).getImportedPathString() + or + m = any(DataFlow::ModuleImportNode im).getPath() + ) and m.regexpMatch("[^./].*") }