Skip to content

Commit 7f51b2d

Browse files
Test fix
1 parent 9d76f62 commit 7f51b2d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/firestore/src/local/indexeddb_remote_document_cache.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,9 @@ class IndexedDbRemoteDocumentCacheImpl implements IndexedDbRemoteDocumentCache {
289289
collection.popLast().toArray(),
290290
collection.lastSegment(),
291291
toDbTimestampKey(offset.readTime),
292-
offset.documentKey.path.lastSegment() || ''
292+
offset.documentKey.path.isEmpty()
293+
? ''
294+
: offset.documentKey.path.lastSegment()
293295
];
294296
const endKey: DbRemoteDocumentKey = [
295297
collection.popLast().toArray(),

0 commit comments

Comments
 (0)