Skip to content

Commit

Permalink
Merge pull request #34336 from rayane-djouah/Migrate-ConfirmedRoute.j…
Browse files Browse the repository at this point in the history
…s-component-to-TypeScript

Fix app crashing on main when route is undefined during Distance Money Request creation

(cherry picked from commit b5bfa47)
  • Loading branch information
grgia authored and OSBotify committed Jan 12, 2024
1 parent 4f1d38d commit ca3e55a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/ConfirmedRoute.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function ConfirmedRoute({mapboxAccessToken, transaction}: ConfirmedRouteProps) {
const {isOffline} = useNetwork();
const {route0: route} = transaction.routes ?? {};
const waypoints = transaction.comment?.waypoints ?? {};
const coordinates = route.geometry?.coordinates ?? [];
const coordinates = route?.geometry?.coordinates ?? [];
const theme = useTheme();
const styles = useThemeStyles();

Expand Down

0 comments on commit ca3e55a

Please sign in to comment.