feat: Set Ollama URL from ollamaInfo in PlaygroundEmpty

This commit is contained in:
farooqpk 2024-11-27 12:40:05 +05:30
parent 2452259189
commit 38979d979b

View File

@ -39,6 +39,13 @@ export const PlaygroundEmpty = () => {
enabled: checkOllamaStatus enabled: checkOllamaStatus
}) })
useEffect(() => {
if (ollamaInfo?.ollamaURL) {
setOllamaURL(ollamaInfo.ollamaURL)
}
}, [ollamaInfo])
if (!checkOllamaStatus) { if (!checkOllamaStatus) {
return ( return (
<div className="mx-auto sm:max-w-xl px-4 mt-10"> <div className="mx-auto sm:max-w-xl px-4 mt-10">