Skip to content

Commit 5e1f03c

Browse files
Update comment
1 parent 9105f02 commit 5e1f03c

File tree

1 file changed

+4
-2
lines changed
  • firebase-firestore/src/main/java/com/google/firebase/firestore/local

1 file changed

+4
-2
lines changed

firebase-firestore/src/main/java/com/google/firebase/firestore/local/LocalStore.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -558,8 +558,10 @@ public void releaseQuery(Query query) {
558558
queryCache.updateQueryData(queryData);
559559
}
560560

561-
// We remove both locally edited documents and documents that are associated via the query
562-
// cache.
561+
// References for documents sent via Watch are automatically removed when we delete a
562+
// query's target data from the reference delegate. Since this does not remove references
563+
// for locally mutated documents, we have to remove the target associations for these
564+
// documents manually.
563565
ImmutableSortedSet<DocumentKey> removedReferences =
564566
localViewReferences.removeReferencesForId(queryData.getTargetId());
565567
for (DocumentKey key : removedReferences) {

0 commit comments

Comments
 (0)