Skip to content

Commit 64bc865

Browse files
authored
Fix ReflectInit exception message (#4317)
1 parent ea41864 commit 64bc865

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/meteordevelopment/meteorclient/utils/ReflectInit.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ private static <T extends Annotation> void reflectInit(Method task, Class<T> ann
6666
try {
6767
task.invoke(null);
6868
} catch (IllegalAccessException | InvocationTargetException e) {
69-
throw new IllegalStateException("Error running @%s task '%s.%s'".formatted(annotation.getSimpleName(), task.getClass().getSimpleName(), task.getName()), e);
69+
throw new IllegalStateException("Error running @%s task '%s.%s'".formatted(annotation.getSimpleName(), task.getDeclaringClass().getSimpleName(), task.getName()), e);
7070
} catch (NullPointerException e) {
7171
throw new RuntimeException("Method \"%s\" using Init annotations from non-static context".formatted(task.getName()), e);
7272
}

0 commit comments

Comments
 (0)