You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a DTO which has constraints. One of them is the UniqueEntity constraint. I have specified the class of the entity to retrieve the good manager. However, the validator tries to retrieve the manager from the class of the DTO (which has not manager and repository).
Symfony version(s) affected: >= 4.4
Description
I have a DTO which has constraints. One of them is the UniqueEntity constraint. I have specified the class of the entity to retrieve the good manager. However, the validator tries to retrieve the manager from the class of the DTO (which has not manager and repository).
How to reproduce
Add a new entry in the database of entity
Entity
with email[email protected]
.Possible Solution
symfony/src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php
Line 71 in 4b8983a
Change this line to:
Additional context
Is it intentional?
The text was updated successfully, but these errors were encountered: