Selaa lähdekoodia

caPrefix删除正则匹配仅支持前缀匹配

(cherry picked from commit c3897bc62c494c52076a29ecfc0925dd38ad5788)
wang 2 vuotta sitten
vanhempi
commit
5688abdce4

+ 1 - 1
class-winter-core/src/main/java/winter/com/ideaaedi/classwinter/util/JavassistUtil.java

@@ -166,7 +166,7 @@ public final class JavassistUtil {
                     AnnotationsAttribute annotationsAttribute = (AnnotationsAttribute) y;
                     Annotation[] annotations = annotationsAttribute.getAnnotations();
                     Annotation[] newAnnotations = Arrays.stream(annotations)
-                            .filter(annotation -> StrUtil.startsWithOrRegMatched(x,annotation.getTypeName()))
+                            .filter(annotation -> !annotation.getTypeName().startsWith(x))
                             .toArray(Annotation[]::new);
                     annotationsAttribute.setAnnotations(newAnnotations);
                 }