Skip to content

Commit 2ea2e4d

Browse files
authored
Add firestore() method to api::QuerySnapshot (#3232)
1 parent 3bdca42 commit 2ea2e4d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Firestore/core/src/firebase/firestore/api/document_change.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#ifndef FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_API_DOCUMENT_CHANGE_H_
1818
#define FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_API_DOCUMENT_CHANGE_H_
1919

20+
#include <memory>
2021
#include <utility>
2122

2223
#include "Firestore/core/src/firebase/firestore/api/document_snapshot.h"
@@ -58,6 +59,10 @@ class DocumentChange {
5859
return new_index_;
5960
}
6061

62+
const std::shared_ptr<Firestore>& firestore() const {
63+
return document_.firestore();
64+
}
65+
6166
/**
6267
* A sentinel return value for old_index() and new_index() indicating that
6368
* there's no relevant index to return because the document was newly added

0 commit comments

Comments
 (0)