sol-journal icon indicating copy to clipboard operation
sol-journal copied to clipboard

Not saving when I'm online

Open dantehemerson opened this issue 4 years ago • 2 comments
trafficstars

I'm online but it's not saving the data. The console gives me the next message: image

dantehemerson avatar Jan 24 '21 16:01 dantehemerson

Also experiencing the same warnings that saving will occur when back online even though I'm already online.

benslv avatar Jan 27 '21 21:01 benslv

Hey @dantehemerson and @silverben10, I take if you've taken steps to set this up on your own instances of Firebase/Firestore?

I have the following rules in my Firestore rules:

service cloud.firestore {
  match /databases/{database}/documents {
    match /{document=**} {
      allow read: if request.auth != null
      		&& request.auth.uid == resource.data.userId
                && request.auth.token.email_verified;
      allow write: if request.auth != null
                && request.auth.token.email_verified;
    }
  }
}

Those kinds of errors look like the kinds of things that happen when the rules aren't set up properly.

It's probably at a url like this:

https://console.firebase.google.com/u/0/project/<project-name>/firestore/rules

This is much less secure, but could be helpful to debug by changing the rules to this:

service cloud.firestore {
  match /databases/{database}/documents {
    match /{document=**} {
      allow read, write;
    }
  }
}

Does that help? Sorry for a slow response to your questions.

gillkyle avatar Feb 10 '21 00:02 gillkyle