aggregation optimization

This commit is contained in:
Emily
2024-09-02 18:37:02 +02:00
parent c003b655ec
commit 023f2b5f4a
3 changed files with 15 additions and 20 deletions

View File

@@ -46,7 +46,7 @@ export async function executeAdvancedTimelineAggregation<T = {}>(options: Advanc
console.log(JSON.stringify(aggregation, null, 2));
}
const timeline: { _id: string, count: number & T }[] = await options.model.aggregate(aggregation, { explain: options.debug === true });
const timeline: { _id: string, count: number & T }[] = await options.model.aggregate(aggregation);
return timeline;