Skip to content

Commit f250443

Browse files
HemangChothanicrwilcox
authored andcommitted
docs(firestore): add documentation for Document,Collection .on_snapshot (#9275)
* add parameters in method on_snapshot of DocumentReference class * docs: add parameters in method on-snapshot of Collection class
1 parent 4963eee commit f250443

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

google/cloud/firestore_v1/collection.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -446,7 +446,7 @@ def on_snapshot(self, callback):
446446
db = firestore_v1.Client()
447447
collection_ref = db.collection(u'users')
448448
449-
def on_snapshot(collection_snapshot):
449+
def on_snapshot(collection_snapshot, changes, read_time):
450450
for doc in collection_snapshot.documents:
451451
print(u'{} => {}'.format(doc.id, doc.to_dict()))
452452

google/cloud/firestore_v1/document.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ def on_snapshot(self, callback):
512512
db = firestore_v1.Client()
513513
collection_ref = db.collection(u'users')
514514
515-
def on_snapshot(document_snapshot):
515+
def on_snapshot(document_snapshot, changes, read_time):
516516
doc = document_snapshot
517517
print(u'{} => {}'.format(doc.id, doc.to_dict()))
518518

0 commit comments

Comments
 (0)