After using toArray() for a cursor does it still need to be closed?

Using Node driver (if that matters) - After using toArray() on a cursor do I still need to issue a cursor.close() ?

Hi @Stuart_76776,

I’d say “no” because toArray() consumes the cursor entirely, so it should be removed from the cluster as well, as the query is done.

Cheers,
Maxime.

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.