Skip to content

Commit 0b2d790

Browse files
tariknzCopilot
andauthored
Update src/frontend/components/TrackMap/tracks/broken-tracks.ts
Co-authored-by: Copilot <[email protected]>
1 parent 46f426b commit 0b2d790

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/frontend/components/TrackMap/tracks/broken-tracks.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,13 @@ export const BROKEN_TRACKS: BrokenTrack[] = [
4646
{ id: 506, name: 'Slinger', issue: 'figure 8' },
4747
];
4848

49-
export const BROKEN_TRACK_IDS = BROKEN_TRACKS.map(track => track.id);
49+
export const BROKEN_TRACK_IDS_SET = new Set(BROKEN_TRACKS.map(track => track.id));
5050

5151
/**
5252
* Check if a track ID is broken
5353
*/
5454
export const isBrokenTrack = (trackId: number): boolean => {
55-
return BROKEN_TRACK_IDS.includes(trackId);
55+
return BROKEN_TRACK_IDS_SET.has(trackId);
5656
};
5757

5858
/**

0 commit comments

Comments
 (0)