Skip to content

Commit

Permalink
Fix ReflectInit exception message (MeteorDevelopment#4317)
Browse files Browse the repository at this point in the history
  • Loading branch information
RacoonDog authored and tyrannus00 committed Apr 25, 2024
1 parent 6b6bcb7 commit fb981ef
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ private static <T extends Annotation> void reflectInit(Method task, Class<T> ann
try {
task.invoke(null);
} catch (IllegalAccessException | InvocationTargetException e) {
throw new IllegalStateException("Error running @%s task '%s.%s'".formatted(annotation.getSimpleName(), task.getClass().getSimpleName(), task.getName()), e);
throw new IllegalStateException("Error running @%s task '%s.%s'".formatted(annotation.getSimpleName(), task.getDeclaringClass().getSimpleName(), task.getName()), e);
} catch (NullPointerException e) {
throw new RuntimeException("Method \"%s\" using Init annotations from non-static context".formatted(task.getName()), e);
}
Expand Down

0 comments on commit fb981ef

Please sign in to comment.