private static @Nullable Class<?> getRepositoryType(@NotNull Task task) {
    TaskRepository repository = task.getRepository();
    return repository != null ? getRepositoryType(repository) : null;
  }
private static @Nullable Class<?> getRepositoryType(@NotNull Task task)