Skip to content

Commit 441cb58

Browse files
tariknzCopilot
andauthored
Update src/frontend/components/FasterCarsFromBehind/hooks/useCarBehind.tsx
Co-authored-by: Copilot <[email protected]>
1 parent b789aa9 commit 441cb58

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/frontend/components/FasterCarsFromBehind/hooks/useCarBehind.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export const useCarBehind = ({
1919

2020
return {
2121
name: carBehind?.driver?.name,
22-
distance: parseFloat(carBehind?.delta.toFixed(1)),
22+
distance: parseFloat(carBehind?.delta?.toFixed(1) ?? '0'),
2323
classColor,
2424
percent: percent,
2525
};

0 commit comments

Comments
 (0)