Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete the secondary skip for a branch route if the branching question is deleted #648

Merged
merged 2 commits into from
Dec 6, 2024

Conversation

lfdebrux
Copy link
Member

@lfdebrux lfdebrux commented Dec 6, 2024

What problem does this pull request solve?

Trello card: https://trello.com/c/UThSZ8ga/2037-fix-behaviour-of-deleting-page-with-secondary-skip-route

It doesn't makes sense to have a secondary skip condition when the precondition skip route has been deleted, but that's currently what happens when you delete a page with a skip and secondary skip.

Instead let's just delete all check conditions for a page when that page is deleted, same as we do for the routing conditions. This shouldn't have any other side effects, as the only case currently where a check condition isn't also a routing condition for a page is for a secondary skip.

Things to consider when reviewing

  • Ensure that you consider the wider context.
  • Does it work when run on your machine?
  • Is it clear what the code is doing?
  • Do the commit messages explain why the changes were made?
  • Are there all the unit tests needed?
  • Has all relevant documentation been updated?

It doesn't makes sense to have a secondary skip condition when the
precondition skip route has been deleted, but that's currently what
happens when you delete a page with a skip and secondary skip.

Instead let's just delete all check conditions for a page when that page
is deleted, same as we do for the routing conditions. This shouldn't
have any other side effects, as the only case currently where a check
condition isn't also a routing condition for a page is for a secondary
skip.
Copy link

sonarqubecloud bot commented Dec 6, 2024

Copy link
Contributor

@thomasiles thomasiles left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good and works 🏅

@lfdebrux lfdebrux merged commit c5cc112 into main Dec 6, 2024
5 checks passed
@lfdebrux lfdebrux deleted the ldeb-change-page-check-condition-to-dependent-delete branch December 6, 2024 10:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants