orderDescending not needed with SortedMap
This commit is contained in:
@ -289,10 +289,6 @@ export const delay = (t: number) => {
|
||||
});
|
||||
};
|
||||
|
||||
export function orderDescending<T>(arr: Array<T & { created_at: number }>) {
|
||||
return arr.sort((a, b) => (b.created_at > a.created_at ? 1 : -1));
|
||||
}
|
||||
|
||||
export function orderAscending<T>(arr: Array<T & { created_at: number }>) {
|
||||
return arr.sort((a, b) => (b.created_at > a.created_at ? -1 : 1));
|
||||
}
|
||||
|
Reference in New Issue
Block a user