Ensure stack initialized when re-applying branch

- set_stack_head could throw without it
- nolith reported this breakage on discord
This commit is contained in:
Mattias Granlund 2024-10-11 10:53:23 +02:00
parent 9e27fea94e
commit 9499bde372

View File

@ -228,6 +228,7 @@ impl BranchManager<'_> {
branch.allow_rebasing = self.ctx.project().ok_with_force_push.into();
branch.in_workspace = true;
branch.initialize(self.ctx)?;
branch
} else {
let upstream_head = upstream_branch.is_some().then_some(head_commit.id());