We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7c644b8 commit 092ee7bCopy full SHA for 092ee7b
src/cursor/abstract_cursor.ts
@@ -732,7 +732,12 @@ export abstract class AbstractCursor<
732
733
try {
734
const response = await this.getMore(batchSize);
735
- if (response) {
+ // CursorResponse is disabled in this PR
736
+ // however the special `emptyGetMore` can be returned from find cursors
737
+ if (CursorResponse.is(response)) {
738
+ this[kId] = response.id;
739
+ this[kDocuments] = response;
740
+ } else if (response?.cursor) {
741
const cursorId = getCursorId(response);
742
this[kDocuments].pushMany(response.cursor.nextBatch);
743
this[kId] = cursorId;
0 commit comments