From 7b4a812bc4f22f66f53a4b2f21d54cd77d53b96b Mon Sep 17 00:00:00 2001 From: aelassas Date: Wed, 22 Jan 2025 19:38:48 +0100 Subject: [PATCH] Update carController.ts --- api/src/controllers/carController.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/controllers/carController.ts b/api/src/controllers/carController.ts index 4f5fe8ea3..4d3c00920 100644 --- a/api/src/controllers/carController.ts +++ b/api/src/controllers/carController.ts @@ -771,7 +771,7 @@ export const getFrontendCars = async (req: Request, res: Response) => { $facet: { resultData: [ { - $sort: { price: 1, _id: 1, comingSoon: -1, fullyBooked: -1 }, + $sort: { price: 1, comingSoon: 1, fullyBooked: 1, _id: 1 }, }, { $skip: (page - 1) * size }, { $limit: size },