Skip to content

Commit

Permalink
Merge pull request #36 from Shinsina/bug-fixes
Browse files Browse the repository at this point in the history
Correct bug causing sort on Season Summary column to break
  • Loading branch information
Shinsina authored Mar 19, 2024
2 parents 699499f + 5f6d1f7 commit 20e3455
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib/layouts/standings.astro
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const finalData: Array<Record<string, any>> = standingsResults.map(
year,
season_number_of_year,
car_class_id,
"Season Summary": season_id,
season_summary: season_id,
division,
division_rank,
overall_rank,
Expand Down Expand Up @@ -73,7 +73,7 @@ const generateLinkForKey = ({
return `/Stat-N-Track/user/${id}/standings/by-year/${resultAtKey}`;
} else if (key === "car_class_id") {
return `/Stat-N-Track/user/${id}/standings/by-car-class/${resultAtKey}`;
} else if (key === "Season Summary") {
} else if (key === "season_summary") {
return `/Stat-N-Track/user/${id}/season/${resultAtKey}/car-class/${carClassId}/season-summary`;
}
return null;
Expand Down
1 change: 1 addition & 0 deletions src/lib/utils/field-id-to-label-map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ export default new Map<string, string>([
["overall_rank", "Rank (Overall)"],
["season_id", "Season ID"],
["season_name", "Season Name"],
["season_summary", "Season Summary"],
["weeks_counted", "Participation Weeks"],
["starts", "Starts"],
["wins", "Wins"],
Expand Down

0 comments on commit 20e3455

Please sign in to comment.