Skip to content

Commit

Permalink
Java 7 compat fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lukehutch committed May 8, 2023
1 parent 94d33a2 commit 2b8ecb9
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ public void testURLs() {
}

public static Set<String> scan(final String annotation, final String urlStr) {
final ClassGraph classGraph = new ClassGraph()
.overrideClasspath(Set.<String> of(urlStr)).disableNestedJarScanning().enableAnnotationInfo();
final ClassGraph classGraph = new ClassGraph().overrideClasspath(urlStr).disableNestedJarScanning()
.enableAnnotationInfo();
try (ScanResult result = classGraph.scan()) {
return result.getClassesWithAnnotation(annotation).getStandardClasses().getNames().stream()
.collect(Collectors.toSet());
Expand Down

0 comments on commit 2b8ecb9

Please sign in to comment.