Fix loading repositories