mirror of
https://github.com/zed-industries/zed.git
synced 2024-09-18 18:08:07 +03:00
Properly propagate git statuses in the outline panel (#13150)
Release Notes: - N/A Co-authored-by: Max <max@zed.dev>
This commit is contained in:
parent
2e87e1d26e
commit
d6d56191da
@ -1769,8 +1769,10 @@ impl OutlinePanel {
|
||||
.into_iter()
|
||||
.map(|(worktree_id, (worktree_snapshot, entries))| {
|
||||
let mut entries = entries.into_iter().collect::<Vec<_>>();
|
||||
project::sort_worktree_entries(&mut entries);
|
||||
// For a proper git status propagation, we have to keep the entries sorted lexicographically.
|
||||
entries.sort_by(|a, b| a.path.as_ref().cmp(b.path.as_ref()));
|
||||
worktree_snapshot.propagate_git_statuses(&mut entries);
|
||||
project::sort_worktree_entries(&mut entries);
|
||||
(worktree_id, entries)
|
||||
})
|
||||
.flat_map(|(worktree_id, entries)| {
|
||||
|
Loading…
Reference in New Issue
Block a user