Update hasNext() documentation

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 4.2.1
    • Affects Version/s: None
    • Component/s: None
    • None
    • 0
    • None
    • Not Needed
    • None
    • None
    • None
    • None
    • 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.

              Assignee:
              Neal Beeken
              Reporter:
              Lauren Schaefer
              None
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: