-
Type: Task
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
Based on discussions in NODE-2307, update the hasNext() documentation https://mongodb.github.io/node-mongodb-native/3.3/api/AggregationCursor.html#hasNext
The documentation implies (to me) that hasNext() would do an asynchronous but fairly immediate check and return either true or false. That doesn't seem to be the case. hasNext() seems to actually be waiting for the next item. It will return true as soon as it gets an item in the changestream. It will only return false if the changestream is closed.