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 3caa44c commit a36e707Copy full SHA for a36e707
source/includes/read/change-streams/change-stream.php
@@ -20,15 +20,6 @@ function toJSON(object $document): string
20
$changeStream = $collection->watch();
21
$changeStream->rewind();
22
23
-do {
24
- $changeStream->next();
25
-
26
- if ($changeStream->valid()) {
27
- $event = $changeStream->current();
28
- echo toJSON($event), PHP_EOL;
29
- }
30
-} while (! $changeStream->valid() || $changeStream->current()['operationType'] !== 'invalidate');
31
32
while (true) {
33
$changeStream->next();
34
0 commit comments