Skip to content

Commit

Permalink
fix: inversion de logique contrôle d'expiration lors d'une candidature (
Browse files Browse the repository at this point in the history
#1749)

* fix: inversion de logique

* fix: real fix
  • Loading branch information
alanlr authored Jan 8, 2025
1 parent 208e009 commit b53a3a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/src/services/application.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ export const sendApplicationV2 = async ({
}
const { recruiter, job } = recruiterResult
// la vérification sur la date accepte une période de grâce de 1j
if (recruiter.status !== RECRUITER_STATUS.ACTIF || job.job_status !== JOB_STATUS.ACTIVE || dayjs(job.job_expiration_date).isBefore(dayjs().add(1, "day"))) {
if (recruiter.status !== RECRUITER_STATUS.ACTIF || job.job_status !== JOB_STATUS.ACTIVE || dayjs(job.job_expiration_date).add(1, "day").isBefore(dayjs())) {
throw badRequest(BusinessErrorCodes.EXPIRED)
}

Expand Down

0 comments on commit b53a3a2

Please sign in to comment.