From 1220e6e33e03a5d5564dd98b8f6d4296ff5987de Mon Sep 17 00:00:00 2001 From: 9sneha-n <9sneha.n@gmail.com> Date: Fri, 8 Nov 2024 21:54:38 +0530 Subject: [PATCH] fix: last updated team builder sort order --- src/data/repositories/utils/IncidentManagementTeamMapper.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/repositories/utils/IncidentManagementTeamMapper.ts b/src/data/repositories/utils/IncidentManagementTeamMapper.ts index 0f6f7a9e..b0cc49b2 100644 --- a/src/data/repositories/utils/IncidentManagementTeamMapper.ts +++ b/src/data/repositories/utils/IncidentManagementTeamMapper.ts @@ -52,7 +52,7 @@ export function mapD2EventsToIncidentManagementTeam( const sortedByUpdatedDates = d2Events.sort(function (a, b) { if (!a.updatedAt) return -1; if (!b.updatedAt) return 1; - return a.updatedAt < b.updatedAt ? -1 : a.updatedAt > b.updatedAt ? 1 : 0; + return a.updatedAt > b.updatedAt ? -1 : a.updatedAt < b.updatedAt ? 1 : 0; }); return new IncidentManagementTeam({