Skip to content

Commit

Permalink
fix: Prevent double modals appearing
Browse files Browse the repository at this point in the history
  • Loading branch information
hannahpurcell committed Jan 6, 2025
1 parent 592dec4 commit 0e396ac
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions assets/src/components/ladderPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -242,13 +242,15 @@ const LadderPage = (): ReactElement<HTMLDivElement> => {
show={showDetourModal}
onClose={() => {
setShowDetourModal(false)
setRouteForDetour(null)
}}
/>
)}
{showDetourModal && detour && (
<DetourModal
onClose={() => {
setShowDetourModal(false)
setDetourId(undefined)
}}
show
key={detourId ?? ""}
Expand Down

0 comments on commit 0e396ac

Please sign in to comment.