Skip to content

Commit e0d4b97

Browse files
authored
pops 2 messages at a time when truncating history (#695)
1 parent c9a5666 commit e0d4b97

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,7 @@ impl ConversationState {
223223
assert!(self.next_message.is_some());
224224
while self.history.len() > MAX_CONVERSATION_STATE_HISTORY_LEN {
225225
self.history.pop_front();
226+
self.history.pop_front();
226227
}
227228

228229
// The current state we want to send

0 commit comments

Comments
 (0)