Merge pull request #1788 from satti-hari-krishna-reddy/nightly

feat: Detect local/self-hosted AI model availability during backend startup
This commit is contained in:
Frikky
2025-08-22 17:24:15 +02:00
committed by GitHub
+3
View File
@@ -1135,6 +1135,8 @@ func handleInfo(resp http.ResponseWriter, request *http.Request) {
}
}
aiEnabled := os.Getenv("OPENAI_API_URL") != "" && os.Getenv("AI_MODEL") != ""
returnValue := shuffle.HandleInfo{
Success: true,
Username: userInfo.Username,
@@ -1159,6 +1161,7 @@ func handleInfo(resp http.ResponseWriter, request *http.Request) {
ActiveApps: activatedAppIds,
Theme: userInfo.Theme,
OrgStatus: parsedStatus,
AIEnabled: aiEnabled,
}
returnData, err := json.Marshal(returnValue)