# project: Refresh MCP settings after worktree changes \(\#62026\) · gitcafe/zed

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

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

Visibility: public

Requested revision: b5764581d2136b48fdad826a36fabe138b887369

Requested commit: b5764581d2136b48fdad826a36fabe138b887369

Commit: b5764581d2136b48fdad826a36fabe138b887369

Tree: 11a8aa7b8b7ed38559879c02aebc316860845ed1

Author: Ben Kunkle

Committer: GitHub

## Message

```
project: Refresh MCP settings after worktree changes (#62026)

# Objective

Prevent MCP servers from remaining unavailable when a project is created
before its first worktree.

## Solution

Refresh effective MCP settings before maintaining servers after worktree
additions or removals.

## 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:

- Agent: Fixed MCP servers missing from new project threads after a
worktree opens.
```

## Parents

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

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