Repository navigation
Refuse les emails sans TLD lors de l'achat de billets d'événement - #2426
Merged
Merged
Conversation
- Use the PHPUnit DataProvider attribute instead of the removed doc-comment annotation so testEmailIsValidated() receives its arguments and all provider rows actually run. - Add NotBlank next to Email on Ticket::email (and on the ticket form email field): Symfony's Email constraint skips empty values, so an empty email would otherwise stay valid.
Korbeil
marked this pull request as ready for review
October 5, 2026 09:40
stakovicz
reviewed
Oct 5, 2026
Le formulaire d'achat pré-remplit la facture avec 15 billets vides
(PurchaseType::MAX_NB_PERSONNES) ; les entrées non soumises de la
collection sont validées et l'email vide violait NotBlank, ce qui
invalide chaque soumission du formulaire de billetterie.
La contrainte Email (mode html5 par défaut) refuse déjà les emails
sans TLD et ignore les valeurs vides : l'objectif du PR est conservé.
- TicketType / Ticket : retrait de NotBlank (et de son import)
- TicketTest : l'email vide est désormais attendu valide (l'Email
ignore les valeurs vides, sur quoi s'appuient les billets vides)
- Ticketing.feature : scénario de régression sur le refus des emails
sans TLD ("Cette valeur n'est pas une adresse email valide.")
Korbeil
force-pushed
the
afup-when-a-customer-take
branch
from
October 5, 2026 13:55
0e7dd5e to
32dee8e
Compare
Korbeil
marked this pull request as draft
October 5, 2026 13:56
stakovicz
approved these changes
Oct 5, 2026
Korbeil
marked this pull request as ready for review
October 5, 2026 14:20
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Lors de l'achat de billets pour un événement, l'email du participant n'était pas validé côté serveur, ce qui permettait de saisir des emails sans extension de domaine (TLD). Ces emails invalides causaient des problèmes en aval. Désormais, un email valide avec un TLD est exigé.
Changes
How to test
jean@localhost) : le formulaire doit être refusé.jean@exemple.fr) : l'achat doit fonctionner.phpunit tests/unit/AppBundle/Event/Model/TicketTest.php.