mirror of
https://github.com/cline/cline.git
synced 2026-10-29 17:42:34 +08:00
* fix(desktop): stop opening a session from replacing the remembered model The composer's ModelSelector mirrored every provider/model prop change into the remembered last selection (localStorage), which seeds new sessions via getInitialChatConfig(). Opening an existing session drives those props to that session's config, so merely viewing an old session silently replaced the user's explicitly picked default model. The remembered selection is now written only from the explicit picker handlers (provider select and model select). Passive prop changes, such as opening a session, no longer touch it. * fix(desktop): re-seed remembered provider/model on chat reset reset() kept the previous config's provider/model and only cleared the session ID, so a chat pane that had hydrated a historical session could carry that session's model into the next chat. Re-seed provider/model (and apiKey when the provider changes) from the remembered defaults -- the same source a freshly mounted thread uses -- so reset and remount behave identically. Co-authored-by: Saoud Rizwan <saoudrizwan@users.noreply.github.com> --------- Co-authored-by: Saoud Rizwan <saoudrizwan@users.noreply.github.com>