Skip to content

Commit

Permalink
fix: address issue where you would have to hit interrupt twice
Browse files Browse the repository at this point in the history
Signed-off-by: tylerslaton <[email protected]>
  • Loading branch information
tylerslaton committed Sep 11, 2024
1 parent 57e1a5c commit 828ff59
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions components/chat/useChatSocket.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,7 @@ const useChatSocket = () => {
socket.on('interrupted', () => {
setGenerating(false);
setWaitingForUserResponse(false);
workQueue.current = [];
setMessages((prevMessages) => {
return [...prevMessages, latestAgentMessageRef.current];
});
Expand Down

0 comments on commit 828ff59

Please sign in to comment.