hoppscotch/firestore.rules

14 lines
547 B
Plaintext
Raw Normal View History

2019-10-03 09:46:39 +00:00
service cloud.firestore {
match /databases/{database}/documents {
2022-01-21 07:43:40 +00:00
// Make sure the uid of the requesting user matches name of the user
2020-01-23 02:32:34 +00:00
// document. The wildcard expression {userId} makes the userId variable
// available in rules.
match /users/{userId} {
2022-01-21 07:43:40 +00:00
allow read, write, create, update, delete: if request.auth.uid != null && request.auth.uid == userId;
}
match /users/{userId}/{document=**} {
allow read, write, create, update, delete: if request.auth.uid != null && request.auth.uid == userId;
2019-10-03 09:46:39 +00:00
}
}
}