Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Fix panic in the git panel when toggling `sort_by_path` (#43074)

Cole Miller5e21457f2162
diff --git a/crates/git_ui/src/git_panel.rs b/crates/git_ui/src/git_panel.rs
index 6889b880623..cd56473dceb 100644
--- a/crates/git_ui/src/git_panel.rs
+++ b/crates/git_ui/src/git_panel.rs
@@ -373,6 +373,7 @@ impl GitPanel {
let is_sort_by_path = GitPanelSettings::get_global(cx).sort_by_path;
if is_sort_by_path != was_sort_by_path {
this.entries.clear();
+ this.bulk_staging.take();
this.update_visible_entries(window, cx);
}
was_sort_by_path = is_sort_by_path