diff --git a/module/rolldata-ajustements.js b/module/rolldata-ajustements.js index d1c6692a..67dd2c78 100644 --- a/module/rolldata-ajustements.js +++ b/module/rolldata-ajustements.js @@ -94,10 +94,10 @@ export const referenceAjustements = { getDescr: (rollData, actor) => rollData.diviseurSignificative > 1 ? `Facteur significative ×${Misc.getFractionHtml(rollData.diviseurSignificative)}` : '' }, isEcaille: { - isVisible: (rollData, actor) => rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0, - isUsed: (rollData, actor) => rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0, + isVisible: (rollData, actor) => rollData.arme?.data.magique && Number(rollData.arme?.data.ecaille_efficacite) > 0, + isUsed: (rollData, actor) => rollData.arme?.data.magique && Number(rollData.arme?.data.ecaille_efficacite) > 0, getLabel: (rollData, actor) => "Ecaille d'Efficacité: ", - getValue: (rollData, actor) => (rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0) ? rollData.arme.data.ecaille_efficacite : 0, + getValue: (rollData, actor) => (rollData.arme?.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0) ? rollData.arme.data.ecaille_efficacite : 0, }, finesse: { isUsed: (rollData, actor) => RdDBonus.isDefenseAttaqueFinesse(rollData),