Skip to content

Commit 8238c99

Browse files
committed
C#: Only include APIs that has a proper namespace.
1 parent 5c13391 commit 8238c99

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

csharp/ql/src/utils/model-generator/internal/CaptureModelsSpecific.qll

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ class Type = CS::Type;
2222
private predicate isRelevantForModels(CS::Callable api) {
2323
[api.(CS::Modifiable), api.(CS::Accessor).getDeclaration()].isEffectivelyPublic() and
2424
not api instanceof CS::ConversionOperator and
25-
not api instanceof Util::MainMethod
25+
not api instanceof Util::MainMethod and
26+
api.getDeclaringType().getNamespace().getQualifiedName() != ""
2627
}
2728

2829
/**

0 commit comments

Comments
 (0)