TagSpaces is an offline, open source, document manager with tagging support
fix chat
sytolk86cdf93d8a4d
diff --git a/src/renderer/components/chat/ChatView.tsx b/src/renderer/components/chat/ChatView.tsxindex d04295ab8..c0b2aa1a6 100644--- a/src/renderer/components/chat/ChatView.tsx+++ b/src/renderer/components/chat/ChatView.tsx@@ -221,9 +221,7 @@ function ChatView() {).then((response) => {console.log('newOllamaMessage response:' + response);- if (response) {- chatMsg.current = '';- }+ chatMsg.current = '';isLoading.current = false;forceUpdate();})diff --git a/src/renderer/hooks/ChatProvider.tsx b/src/renderer/hooks/ChatProvider.tsxindex ad96fb11f..63ec1c4f0 100644--- a/src/renderer/hooks/ChatProvider.tsx+++ b/src/renderer/hooks/ChatProvider.tsx@@ -979,11 +979,12 @@ export const ChatContextProvider = ({ children }: ChatContextProviderProps) => {chatMessageHandler,).then((apiResponse) => {// console.log('apiResponse:' + apiResponse);- if (apiResponse === undefined) {+ isTyping.current = false;+ forceUpdate();+ if (apiResponse === undefined && stream === false) {showNotification('Error check if Ollama service is alive');return undefined;}- isTyping.current = false;if (msg && includeHistory) {saveHistoryItems();}