Skip to content

Commit

Permalink
[MIM-2162] Fix average year validation for Pif Calculator (#3086)
Browse files Browse the repository at this point in the history
Fix average year validation for Pif Calculator
MIM-2162
  • Loading branch information
johnnadeluy authored Jan 9, 2025
1 parent 585d65b commit d29c852
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/resources/react4xp/_entries/PifCalculator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ function PifCalculator(props: PifCalculatorProps) {
const endMonthValue = value || endMonth.value.id
const maxYearAverage = Number(validMaxMonth) === 12 ? validMaxYear : Number(validMaxYear) - 1
const endMonthValid =
endMonthValue === ''
endMonthValue === '90'
? endYear.value <= maxYearAverage
: !(endYear.value === validMaxYear && endMonthValue > validMaxMonth)
if (!endMonthValid) {
Expand Down

0 comments on commit d29c852

Please sign in to comment.