Skip to content

Commit

Permalink
prevent screen to crash due re render issue on network switch (#2357)
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianscatularo committed Aug 10, 2024
1 parent dfbcc7b commit 8d32980
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wormhole-connect/src/views/Bridge/RouteOptions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ function RouteOption(props: {
return REASON_AMOUNT_TOO_LOW;
}
}, [manualAddressTarget, props]);

const Icon = useCallback(() => props.route.icon(), [props]);
return (
fromTokenConfig &&
toTokenConfig && (
Expand Down Expand Up @@ -341,7 +341,7 @@ function RouteOption(props: {
/>
<ArrowRightIcon fontSize={mobile ? 'inherit' : undefined} />
<Tag
icon={props.route.icon()}
icon={<Icon />}
text={props.route.routePath || props.route.providedBy}
/>
<ArrowRightIcon fontSize={mobile ? 'inherit' : undefined} />
Expand Down

0 comments on commit 8d32980

Please sign in to comment.