# Do not fail hard on selection persistence if the editor is removed \(\#25120\) · gitcafe/zed

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

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

Visibility: public

Requested revision: 92f128ebb0996d162eb01cb85248509d276da1ef

Requested commit: 92f128ebb0996d162eb01cb85248509d276da1ef

Commit: 92f128ebb0996d162eb01cb85248509d276da1ef

Tree: 24a8842c8073ec11964b1d269e10131021a5f680

Author: Kirill Bulatov

Committer: GitHub

## Message

```
Do not fail hard on selection persistence if the editor is removed (#25120)

Follow-up of https://github.com/zed-industries/zed/pull/25083

Follows practices from editors' scroll position persisting:
https://github.com/zed-industries/zed/blob/5a05b7461e476d7ddc59418868ebdab6687b8d2f/crates/editor/src/persistence.rs#L200
and do not fail hard if the editor with the ID given does not exist.
Also add the problematic IDs into the error context to see them in the
error logs.

Release Notes:

- N/A
```

## Parents

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

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