This commit is contained in:
Simon Knott 2025-02-14 10:36:16 +01:00
parent fa81f6f16d
commit 366fde13ce
No known key found for this signature in database
GPG key ID: 8CEDC00028084AEC
3 changed files with 3 additions and 3 deletions

View file

@ -183,7 +183,7 @@ export function AIErrorConversation({ conversationId, error, pageSnapshot, diff
displayContent += ` Take the page snapshot into account.`;
conversation.send(content, displayContent);
}, [conversation]);
}, [conversation]); // eslint-disable-line react-hooks/exhaustive-deps
return <AIConversation history={history} conversation={conversation} />;
}

View file

@ -244,7 +244,7 @@ export function useLLMConversation(id: string, systemPrompt: string) {
const chat = useLLMChat();
if (!chat)
throw new Error('No LLM chat available, make sure theres a LLMProvider above');
const conversation = React.useMemo(() => chat.getConversation(id, systemPrompt), [chat, id]);
const conversation = React.useMemo(() => chat.getConversation(id, systemPrompt), [chat, id]); // eslint-disable-line react-hooks/exhaustive-deps
const [history, setHistory] = React.useState(conversation.history);
React.useEffect(() => {
function update() {

View file

@ -255,6 +255,6 @@ export function useCookies() {
const separator = kv.indexOf('=');
return [kv.substring(0, separator), kv.substring(separator + 1)];
});
}, [document.cookie]);
}, []);
return cookies;
}