fix: clear chat button

This commit is contained in:
Udhay-Adithya
2025-09-27 16:22:33 +05:30
parent 991b2c69f7
commit ec02eb640f

View File

@@ -265,7 +265,11 @@ class ChatViewmodel extends StateNotifier<ChatState> {
final id = _currentRequest?.id ?? 'global'; final id = _currentRequest?.id ?? 'global';
final newSessions = {...state.chatSessions}; final newSessions = {...state.chatSessions};
newSessions[id] = []; newSessions[id] = [];
state = state.copyWith(); state = state.copyWith(
chatSessions: newSessions,
isGenerating: false,
currentStreamingResponse: '',
);
} }
Future<void> sendTaskMessage(ChatMessageType type) async { Future<void> sendTaskMessage(ChatMessageType type) async {