From 922aaa05341584a823be0d59dfafee083d3c74c2 Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Mon, 3 Mar 2025 16:36:13 -0800 Subject: [PATCH] Show git panel footer even when on a detached HEAD (#25968) Previously, the git panel footer would accidentally hide when not on a branch. Release Notes: - N/A Co-authored-by: Ben Kunkle --- crates/git_ui/src/git_panel.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/git_ui/src/git_panel.rs b/crates/git_ui/src/git_panel.rs index f76d8b2bda6818ca517154f24ef1e8b4b8fe030c..f516341731aa75c497b475ec97d2edaee55aa35b 100644 --- a/crates/git_ui/src/git_panel.rs +++ b/crates/git_ui/src/git_panel.rs @@ -2006,7 +2006,7 @@ impl GitPanel { }; let editor_focus_handle = self.commit_editor.focus_handle(cx); - let branch = active_repo.read(cx).current_branch()?.clone(); + let branch = active_repo.read(cx).current_branch().cloned(); let footer_size = px(32.); let gap = px(8.0); @@ -2027,7 +2027,7 @@ impl GitPanel { .child(PanelRepoFooter::new( "footer-button", display_name, - Some(branch), + branch, Some(git_panel), Some(branches), ))