change wrong annotation class usage
This commit is contained in:
parent
4332592dfa
commit
aefd8a51a0
@ -14,7 +14,7 @@ public record AppliedCheck(InteractionCheck<?> check, Annotation annotation) {
|
|||||||
.filter(x -> x.getName().equals("preExec"))
|
.filter(x -> x.getName().equals("preExec"))
|
||||||
.filter(x -> !x.isBridge())
|
.filter(x -> !x.isBridge())
|
||||||
.toArray(s -> new Method[s]);
|
.toArray(s -> new Method[s]);
|
||||||
Method method = ReflectionUtil.getMostSpecificMethod(methods, context.getClass(), annotation.getClass());
|
Method method = ReflectionUtil.getMostSpecificMethod(methods, context.getClass(), annotation.annotationType());
|
||||||
method.setAccessible(true);
|
method.setAccessible(true);
|
||||||
try {
|
try {
|
||||||
return (boolean) method.invoke(check, context, annotation);
|
return (boolean) method.invoke(check, context, annotation);
|
||||||
@ -29,7 +29,7 @@ public record AppliedCheck(InteractionCheck<?> check, Annotation annotation) {
|
|||||||
.filter(x -> x.getName().equals("postExec"))
|
.filter(x -> x.getName().equals("postExec"))
|
||||||
.filter(x -> !x.isBridge())
|
.filter(x -> !x.isBridge())
|
||||||
.toArray(s -> new Method[s]);
|
.toArray(s -> new Method[s]);
|
||||||
Method method = ReflectionUtil.getMostSpecificMethod(methods, context.getClass(), annotation.getClass());
|
Method method = ReflectionUtil.getMostSpecificMethod(methods, context.getClass(), annotation.annotationType());
|
||||||
method.setAccessible(true);
|
method.setAccessible(true);
|
||||||
try {
|
try {
|
||||||
method.invoke(check, context, annotation);
|
method.invoke(check, context, annotation);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user