using estimated document count instead of a deprecated function

This commit is contained in:
Jack 2021-09-17 22:07:44 +01:00
parent d8de31409a
commit f38733da10

View file

@ -25,7 +25,7 @@ class LeaderboardsDAO {
if (res)
res.count = await mongoDB()
.collection(`leaderboards.${language}.${mode}.${mode2}`)
.count();
.estimatedDocumentCount();
return res;
}