Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: Clean code

Daniel7160aa8b3a1d
diff --git a/kernel/util/net.go b/kernel/util/net.go
index fc55bd159e..e8c6dc6f7a 100644
--- a/kernel/util/net.go
+++ b/kernel/util/net.go
@@ -121,7 +121,6 @@ func isOnline(checkURL string, skipTlsVerify bool, timeout int) (ret bool) {
for i := 0; i < 2; i++ {
resp, err := c.R().Get(checkURL)
-
if resp.GetHeader("Location") != "" {
return true
}
@@ -140,8 +139,8 @@ func isOnline(checkURL string, skipTlsVerify bool, timeout int) (ret bool) {
break
}
- time.Sleep(1 * time.Second)
logging.LogWarnf("check url [%s] is online failed: %s", checkURL, err)
+ time.Sleep(1 * time.Second)
}
return
}