firebase / snippets-web

Web snippets for firebase.google.com
Apache License 2.0
752 stars 241 forks source link

Update get_document.js #335

Closed Shabbirjodhpur closed 1 year ago

Shabbirjodhpur commented 1 year ago

We get the snapshot of data using 'getDoc()' and get result 'docSnap' And then we perform check on this 'docSnap' in the if else block So in the else block the comment should ne docSnap.data() will ne undefined

google-cla[bot] commented 1 year ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

thatfiredev commented 1 year ago

@Shabbirjodhpur good find!

However, this file was generated from firestore-next/test.firestore.js:

https://github.com/firebase/snippets-web/blob/486e5c67bcb895a00ccab90f1b20cefdba6c9e3a/firestore-next/test.firestore.js#L586

Can you please edit that file instead?

And then you should run npm run snippets to re-generate the appropriate files and commit them.

Thanks!

Shabbirjodhpur commented 1 year ago

This was my first PR !!! I am so excited!! It was great working on it !!!