Skip to content

Commit

Permalink
bug 189595 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoGoC committed Mar 27, 2024
1 parent 60302f1 commit 199dbc4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion utils/api/definitions/schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,11 @@ export const RequestSchema = Joi.object({
})
}

const duration: MonthsYears = JSON.parse(oasDeferDuration)
const duration: MonthsYears =
oasDeferDuration !== undefined
? JSON.parse(oasDeferDuration)
: { years: 0, months: 0 }

const durationFloat = duration.years + duration.months / 12

if (livingCountry === LivingCountry.CANADA) {
Expand Down

0 comments on commit 199dbc4

Please sign in to comment.