chore: up mongo deps (#11375)

* chore: up mongo deps

* mongodb 5.x no more callbacks
isekai-main
Barış Soner Uşaklı 2 years ago committed by GitHub
parent 75436dc02c
commit 5db037f1ea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -50,7 +50,7 @@
"compare-versions": "5.0.3",
"compression": "1.7.4",
"connect-flash": "0.1.1",
"connect-mongo": "4.6.0",
"connect-mongo": "5.0.0",
"connect-multiparty": "2.2.0",
"connect-pg-simple": "8.0.0",
"connect-redis": "6.1.3",
@ -85,7 +85,7 @@
"material-design-lite": "1.3.0",
"mime": "3.0.0",
"mkdirp": "2.1.5",
"mongodb": "4.14.0",
"mongodb": "5.1.0",
"morgan": "1.10.0",
"mousetrap": "1.6.5",
"multiparty": "4.2.3",

@ -173,9 +173,8 @@ async function getCollectionStats(db) {
return await Promise.all(items.map(collection => db.collection(collection.name).stats()));
}
mongoModule.close = function (callback) {
callback = callback || function () {};
client.close(err => callback(err));
mongoModule.close = async function () {
await client.close();
};
require('./mongo/main')(mongoModule);

Loading…
Cancel
Save