Make sync-database.ts log *way* less stuff.

This commit is contained in:
zkldi
2021-12-24 04:47:11 +00:00
parent 9fd9577f67
commit 96073cc0c2
+10 -2
View File
@@ -96,8 +96,16 @@ async function GenericUpsert<T>(
if (bwriteOps.length === 0) {
logger.verbose(`No differences. Not performing any update.`);
} else {
const result = await collection.bulkWrite(bwriteOps);
logger.info(`Performed bulkWrite.`, result);
const { deletedCount, insertedCount, matchedCount, upsertedCount, modifiedCount } =
await collection.bulkWrite(bwriteOps);
logger.info(`Performed bulkWrite.`, {
deletedCount,
insertedCount,
matchedCount,
upsertedCount,
modifiedCount,
});
await InitaliseFolderChartLookup();
}