}
private int countDistroFiles(EntityManager entityManager, String label) {
Query query = entityManager.createNamedQuery(Distribution.QUERY_FIND_BY_DIST_LABEL);
query.setParameter("label", label);
Distribution distro = (Distribution) query.getSingleResult();
query = entityManager.createNamedQuery(DistributionFile.SELECT_BY_DIST_ID);
query.setParameter("distId", distro.getId());
List distroFiles = query.getResultList();
if (distroFiles == null) {
return 0;
} else {