# Refactor draft thread lookups and cache persisted draft state · gitcafe/t3code

[View on GitCafe](https://git.cafe/gitcafe/t3code/commit/6ab246676ebaee8ef895ab4067fb6457854b0a1c)

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

Visibility: public

Requested revision: 6ab246676ebaee8ef895ab4067fb6457854b0a1c

Requested commit: 6ab246676ebaee8ef895ab4067fb6457854b0a1c

Commit: 6ab246676ebaee8ef895ab4067fb6457854b0a1c

Tree: 3218448eda579de34067dea5f2dfb43b9153c296

Author: Julius Marminge

Committer: Julius Marminge

## Message

```
Refactor draft thread lookups and cache persisted draft state

- replace `read*` draft selectors with `getDraftThread`/`getDraftThreadByProjectId`
- centralize persisted localStorage parsing/caching in `composerDraftStore`
- make ChatView fallback read persisted attachments from in-memory store state

```

## Parents

- [122c94a24acf31d72097faad3e943e939e7fff91](https://git.cafe/gitcafe/t3code/commit/122c94a24acf31d72097faad3e943e939e7fff91?format=markdown)

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