Skip to content

Commit

Permalink
SimpleTableManual sort on empty values incorrect on Firefox issue fix…
Browse files Browse the repository at this point in the history
…ed (#422)

Co-authored-by: mashm <[email protected]>
Co-authored-by: tumms2021389 <[email protected]>
  • Loading branch information
3 people authored Nov 19, 2024
1 parent f5ed724 commit c9fbcf2
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,9 @@ export default function SimpleTableManual(props: PropsWithChildren<SimpleTableMa
};

function descendingComparator<T>(a: T, b: T, orderedBy: keyof T) {
if (!orderedBy || (!a[orderedBy] && !b[orderedBy])) {
return 0;
}
if (!b[orderedBy] || b[orderedBy] < a[orderedBy]) {
return -1;
}
Expand Down

0 comments on commit c9fbcf2

Please sign in to comment.