# git_panel: Fix stale Git status entries for moved directories \(\#59934\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/33473c1cd3b6555145e12e39590c6790077088a1)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 33473c1cd3b6555145e12e39590c6790077088a1

Requested commit: 33473c1cd3b6555145e12e39590c6790077088a1

Commit: 33473c1cd3b6555145e12e39590c6790077088a1

Tree: 5256427a2c3f27df47fa3018f365ac71ad79255c

Author: Bing Wang

Committer: GitHub

## Message

```
git_panel: Fix stale Git status entries for moved directories (#59934)

# Objective

Fix stale Git status entries for moved directories

## Solution

Coalesce changed paths before scanning and remove cached descendant
statuses when a directory disappears from the current status set.



## Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content adheres to Zed's UI standards
([UX/UI](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
and
[icon](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md)
guidelines)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable



---

Release Notes:

- Fixed stale Git status entries for moved directories
```

## Parents

- [7582bf74349f6084d4f7370ebb8215d70f7105cf](https://git.cafe/gitcafe/zed/commit/7582bf74349f6084d4f7370ebb8215d70f7105cf?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/33473c1cd3b6555145e12e39590c6790077088a1?format=markdown)
