diff --git a/src/data/checkDataConsistency.ts b/src/data/checkDataConsistency.ts index b0433da..dd91e75 100644 --- a/src/data/checkDataConsistency.ts +++ b/src/data/checkDataConsistency.ts @@ -46,19 +46,6 @@ function checkFamilyDataConsistency(family: Famille) { issueType: "startResistsant > endResistant ", }); } - } else { - if (family.Integration !== null) { - consistencyIssues.push({ - familyId: family.Titre, - issueType: family.Statut + " with startResistant", - }); - } - if (family.Sortie !== null) { - consistencyIssues.push({ - familyId: family.Titre, - issueType: family.Statut + " with endResistant", - }); - } } consistencyIssues.push( ...family.Evenements.filter((e) => !isValidEvenementFamille(e.Type)).map( diff --git a/src/index.ts b/src/index.ts index 828b331..4e69d1b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -25,6 +25,8 @@ import { computeELStats } from "./statistiques/computeELStats"; if (consistencyIssues.length > 0) { console.log("Found consistency issues:"); console.log(consistencyIssues); + console.log("Exiting."); + process.exit(1); } const currentDate = new Date(Date.now());