Skip to content

Commit

Permalink
[MDS-6305] Fix navigation to review & submit page sometimes not worki…
Browse files Browse the repository at this point in the history
…ng (#3356)
  • Loading branch information
simensma-fresh authored Dec 20, 2024
1 parent 72979bd commit d2c74f0
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,13 @@ export const MajorMineApplicationPage: FC = () => {
const defaultCurrent = routeState?.current ?? 0;
const [current, setCurrent] = useState(defaultCurrent);

useEffect(() => {
if (defaultCurrent !== current) {
// Make sure the current step is updated if the rootState changes
setCurrent(defaultCurrent);
}
}, [defaultCurrent]);

const [loaded, setLoaded] = useState(false);
const [confirmedSubmission, setConfirmedSubmission] = useState(false);
const majorMineApplicationGuid =
Expand Down

0 comments on commit d2c74f0

Please sign in to comment.