diff --git a/components/scoreplaylog/colums.tsx b/components/scoreplaylog/colums.tsx index c1d3d0f..293fd35 100644 --- a/components/scoreplaylog/colums.tsx +++ b/components/scoreplaylog/colums.tsx @@ -60,8 +60,8 @@ export const columns: ColumnDef[] = [ }, cell: ({ row }) =>
{row.original.score?.toLocaleString()}
, sortingFn: (a, b) => { - const highScore = a.original.score; - const lowScore = b.original.score; + const highScore = a.original.score ?? 0; + const lowScore = b.original.score ?? 0; if (highScore < lowScore) return 1; if (highScore > lowScore) return -1;