-
Notifications
You must be signed in to change notification settings - Fork 440
Atomic multi-location update #313
Comments
Hi @lorcanfurey this is already working, just missing from the docs, check question and example from this issue #229 davor |
Thanks for the heads up @davorpeic! |
I just tried the atomic multi-location update. The behavior that I seem to be getting is a complete overwrite of the all the keys in the path specified. Is this the intended behavior? Since we are using update I thought only the value of the specified keys would be updated and the rest of the keys would remain unchanged. Thanks |
Just verified, I am also experiencing @anuragd7 's issue; all other fields at the intended path get nuked Any ideas @davorpeic ? |
Hey @anuragd7 and @lorcanfurey One possible workaround would be defining each field you want to update as separate update, and update it as a part of atomic update, that way you would actually update each individual field needed to be updated? This is not tested, but I suppose it should work, can you try?
dp |
Hi @davorpeic, That's what I ended up doing and can confirm it works.👍 |
Thanks for this guys. If anyone is up for an update of the plugin docs I'd be happy to merge a PR. |
Scrap that - that's exactly what @davorpeic has already done ;) |
Hi! Would it be difficult to add atomic multi-location updates as shown in this Firebase Blog post:
I can try my hand on a pull request (tbh wary, first-ever PR if so) but:
The text was updated successfully, but these errors were encountered: