Relationship with unique: true does not work in Postgres
Relationship with unique: true does not work in Postgres. (Untested in mongodb)
beta.30, db-postgres
to reproduce, create a collection which has a Field of type relationship, setting unique: true and proceed to create multiple documents, linking to the same relation.
In the following repo, you can observe it in the posts collection, where I attempt to make the Post.author unique, but I am able to create as many Post documents as I wish, with the same user being related to it.
https://github.com/HarleySalas/payload-3-reproductions/tree/unique-relationship
PR here! https://github.com/payloadcms/payload/pull/8432
PR here! #8432
thank you for so many useful fixes lately!
🚀 This is included in version v3.0.0-beta.114
This issue has been automatically locked. Please open a new issue if this issue persists with any additional detail.