diff --git a/frontend/src/utilities/sortByCreatedAt.ts b/frontend/src/utilities/sortByCreatedAt.ts index 83ecf0236a..b54396dbb2 100644 --- a/frontend/src/utilities/sortByCreatedAt.ts +++ b/frontend/src/utilities/sortByCreatedAt.ts @@ -1,3 +1,2 @@ -export const sortByCreatedAt = (array: any[]): any[] => { - return array.sort((a, b) => new Date(b.created_at).getTime() - new Date(a.created_at).getTime()); -}; +export const sortByCreatedAt = (pipeline) => + pipeline.sort((a, b) => new Date(b.created_at).getTime() - new Date(a.created_at).getTime());