Skip to content

Commit ebb1fff

Browse files
committed
ser&des modelid in cs
1 parent 1a3c32d commit ebb1fff

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

crates/chat-cli/src/cli/chat/conversation_state.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ pub struct ConversationState {
107107
pub updates: Option<SharedWriter>,
108108
/// Model explicitly selected by the user in this conversation state via `/model`. (`None` ==
109109
/// auto)
110-
#[serde(skip)]
110+
#[serde(default, skip_serializing_if = "Option::is_none")]
111111
pub current_model_id: Option<String>,
112112
}
113113

@@ -162,7 +162,7 @@ impl ConversationState {
162162
context_message_length: None,
163163
latest_summary: None,
164164
updates,
165-
current_model_id: current_model_id,
165+
current_model_id,
166166
}
167167
}
168168

0 commit comments

Comments
 (0)