Assuming that there was a:
PR1based on branchmainPR2based on PR1
And after squash-merging PR1 into the main branch,
sometimes we can't just merge PR2 due to a conflicts arising from the commits in PR1 being squashed.
Here's the step-by-step explanation of the Git workflow to resolve this issue:
git switch PR1# if branch was deleted - restore it