You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I used to use the { limit: Infinity, offset: 0 } feature to get all the items while using mongoose paginate module as pagination parameters.
After updating the version of my mongoose and mongoose paginate module it seems to have stopped working. Please suggest the new solution. limit value must be non-negative
Old NPM version of of mongoose and mongoose paginate.
Setting limit to Number.MAX_SAFE_INTEGER seems to work fine. Not exactly sure why Infinity is not working, but I guess it has something to do with accepted cursor limits on the Mongo driver.
Hey Guys,
I used to use the
{ limit: Infinity, offset: 0 }
feature to get all the items while using mongoose paginate module as pagination parameters.After updating the version of my mongoose and mongoose paginate module it seems to have stopped working. Please suggest the new solution.
limit value must be non-negative
Old NPM version of of mongoose and mongoose paginate.
{"mongodb":"1.4.38", "mongoose": "3.8.8", "mongoose-paginate": "5.0.0"}
New NPM version:
"mongodb":"2.2.16", "mongoose": "4.7.3", "mongoose-paginate": "5.0.0"
Mongo Database Version: 3.2
This is where I learned about infinity feature
Thanks for the help.
RR
The text was updated successfully, but these errors were encountered: