The 2nd and 3rd rule in the below code work as expected. I'm trying to specify the access conditions for the mailingList
collection to allow anyone to write. However, this is always blocking.
service cloud.firestore {
match /databases/{database}/documents {
match /malingList/{doc} {
allow write: if true;
}
match /metadata/{doc} {
allow read: if request.auth.uid != null;
}
match /taken/{doc}{
allow read: if request.auth.uid != null;
allow read,write: if
request.auth.uid == doc;
}
}
}
CodePudding user response:
It seems that you have a typo:
Rules => match /malingList/{doc} {}
without i
between a
and l
but you want to write to the mailingList
collection.