PASS IAE: suppression lors de l'annulation de la dernière candidature acceptée [GEN-2032]#4902
Conversation
Only consider accepted job applications
tonial
left a comment
There was a problem hiding this comment.
Si le principe, oui, c'est mieux, mais ça ne corrige pas la faille de sécurité (cf le commentaire que j'ai ajouté à la carte notion)
|
Oui on est d'accord, ça corrige le code pour qu'il fasse ce qui est attendu par le métier mais oui il y a toujours l'autre faille (qui n'a pour le moment pas de solution métier) |
| JobApplication = self.jobapplication_set.model | ||
| try: | ||
| return self.jobapplication_set.get().state == job_application_enums.JobApplicationState.ACCEPTED | ||
| return self.jobapplication_set.filter(state=job_application_enums.JobApplicationState.ACCEPTED).get() |
There was a problem hiding this comment.
Quitte à changer, on aurait pu faire self.jobapplication_set.get(state=job_application_enums.JobApplicationState.ACCEPTED)
There was a problem hiding this comment.
👍 mais c'est déjà mergé 😬 👀
There was a problem hiding this comment.
Il n’y avait pas une règle d’attendre 24h-48h avant de merger, pour laisser à tout le monde le temps d’intervenir dans la discussion ? 😇
There was a problem hiding this comment.
Ah oui, cela me dit vaguement quelque chose maintenant que tu le mentionnes 👼
🤔 Pourquoi ?
Car c'est ce qu'on souhaite.
🍰 Comment ?
🚨 À vérifier
🏝️ Comment tester
💻 Captures d'écran