My Firestore database looks like this
For documents I use dynamic IDs. I do not use the user ID in the path, it is stored in the field. The fields have the values user
and active
.
How can I prevent adding new entries if, for example, the user 37870283 already has an active = true?