merge branch closes window (#882)

fixes #876
This commit is contained in:
andrewpollack 2021-08-30 03:16:37 -07:00 committed by GitHub
parent 361e1d86e9
commit 3a1c1a6b99
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View file

@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- added scrollbar to revlog [[@ashvin021](https://github.com/ashvin021)] ([#868](https://github.com/extrawurst/gitui/issues/868))
## Fixed
- fix merging branch not closing branch window [[@andrewpollack](https://github.com/andrewpollack)] ([#876](https://github.com/extrawurst/gitui/issues/876))
- fix commit msg being broken inside tag list ([#871](https://github.com/extrawurst/gitui/issues/871))
- fix filetree file content not showing tabs correctly ([#874](https://github.com/extrawurst/gitui/issues/874))

View file

@ -362,12 +362,13 @@ impl BranchListComponent {
!self.branches.is_empty()
}
fn merge_branch(&self) -> Result<()> {
fn merge_branch(&mut self) -> Result<()> {
if let Some(branch) =
self.branches.get(usize::from(self.selection))
{
sync::merge_branch(CWD, &branch.name)?;
self.hide();
self.queue.push(InternalEvent::Update(NeedsUpdate::ALL));
}