Skip to content

Commit

Permalink
fix(app): do not navigate back to onboarding
Browse files Browse the repository at this point in the history
  • Loading branch information
tamslo committed Nov 15, 2023
1 parent 0f4a5b6 commit 1b2989e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion app/lib/onboarding/pages/onboarding.dart
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,11 @@ class OnboardingPage extends HookWidget {
key: Key('nextButton'),
onPressed: () {
if (isLastPage) {
context.router.push(DrugSelectionRouter());
// Replace whole stack, see https://stackoverflow.com/a/73784156
context.router.pushAndPopUntil(
DrugSelectionRouter(),
predicate: (_) => false
);
} else {
pageController.nextPage(
duration: Duration(milliseconds: 500),
Expand Down

0 comments on commit 1b2989e

Please sign in to comment.