Skip to content

Commit

Permalink
CONSOMMATIONENERGETIQUE optional
Browse files Browse the repository at this point in the history
  • Loading branch information
ggrossetie authored Feb 25, 2024
1 parent baa5855 commit 87c297a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/pericles.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ async function getPropertiesFromXml(xmlFile) {
property.withPostalCode(p['LOCALISATION']['CODE_POSTAL'])
if (category === 'maison' || category === "appartement") {
const detail = p['MAISON'] || p['APPARTEMENT']
property.withEnergyConsumptionClass(detail['CONSOMMATIONENERGETIQUE'])
property.withEnergyConsumptionClass('CONSOMMATIONENERGETIQUE' in detail && detail['CONSOMMATIONENERGETIQUE'])
property.withGES(detail['GAZEFFETDESERRE'])
property.withFloorArea(detail['SURFACE_HABITABLE'])
property.withRooms(detail['NBRE_CHAMBRES'])
Expand Down

0 comments on commit 87c297a

Please sign in to comment.