[docs][Firestore] Update incorrect get example

Fixes #488
This commit is contained in:
Michael Diarmid 2017-10-11 01:59:11 +01:00 committed by GitHub
parent a89e741581
commit 2ac339d846
1 changed files with 4 additions and 2 deletions

View File

@ -69,14 +69,16 @@ import firebase from 'react-native-firebase';
firebase.firestore() firebase.firestore()
.doc('posts/posts1') .doc('posts/posts1')
.get((documentSnapshot) => {  .get()
 .then((documentSnapshot) => {
const value = documentSnapshot.data(); const value = documentSnapshot.data();
}); });
firebase.firestore() firebase.firestore()
.collection('posts') .collection('posts')
.doc('posts1') .doc('posts1')
.get((documentSnapshot) => {  .get()
 .then((documentSnapshot) => {
const value = documentSnapshot.data(); const value = documentSnapshot.data();
}); });
``` ```