doctrine / DoctrineMongoDBBundle

Integrates Doctrine MongoDB ODM with Symfony
http://symfony.com/doc/current/bundles/DoctrineMongoDBBundle/index.html
MIT License
379 stars 229 forks source link

support Unique constraint as attribute #705

Closed IonBazan closed 2 years ago

IonBazan commented 2 years ago

This change allows using Unique constraint as attribute:

#[Unique()]

see https://github.com/symfony/symfony/blob/5.4/src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntity.php