From 38dd9ae869eabd561559964ac70cfb1ca54d9892 Mon Sep 17 00:00:00 2001 From: zaaarf Date: Wed, 15 Mar 2023 12:07:45 +0100 Subject: fix: repeatable annotation support fix --- src/main/java/ftbsc/lll/processor/LilleroProcessor.java | 1 - src/main/java/ftbsc/lll/processor/tools/ASTUtils.java | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'src/main') diff --git a/src/main/java/ftbsc/lll/processor/LilleroProcessor.java b/src/main/java/ftbsc/lll/processor/LilleroProcessor.java index a2a42f2..a872e3c 100644 --- a/src/main/java/ftbsc/lll/processor/LilleroProcessor.java +++ b/src/main/java/ftbsc/lll/processor/LilleroProcessor.java @@ -23,7 +23,6 @@ import javax.tools.StandardLocation; import java.io.*; import java.net.URI; import java.net.URISyntaxException; -import java.net.URL; import java.nio.charset.StandardCharsets; import java.util.*; import java.util.stream.Collectors; diff --git a/src/main/java/ftbsc/lll/processor/tools/ASTUtils.java b/src/main/java/ftbsc/lll/processor/tools/ASTUtils.java index fb6806e..8361367 100644 --- a/src/main/java/ftbsc/lll/processor/tools/ASTUtils.java +++ b/src/main/java/ftbsc/lll/processor/tools/ASTUtils.java @@ -31,7 +31,7 @@ public class ASTUtils { public static List findAnnotatedMethods(TypeElement cl, Class ann) { return cl.getEnclosedElements() .stream() - .filter(e -> e.getAnnotation(ann) != null) + .filter(e -> e.getAnnotationsByType(ann).length != 0) .map(e -> (ExecutableElement) e) .collect(Collectors.toList()); } -- cgit v1.2.3-56-ga3b1