🎨 Proxy setting sometimes cancel requests https://github.com/siyuan-note/siyuan/issues/9725

This commit is contained in:
Daniel 2023-11-24 21:47:51 +08:00
parent b1985eac74
commit 3c755b1864
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
2 changed files with 5 additions and 1 deletions

View file

@ -34,7 +34,6 @@ func ServeAPI(ginServer *gin.Engine) {
ginServer.Handle("POST", "/api/system/logoutAuth", model.LogoutAuth)
ginServer.Handle("GET", "/api/system/getCaptcha", model.GetCaptcha)
ginServer.Handle("POST", "/api/system/setUILayout", setUILayout) // 这里不加鉴权 After modifying the access authentication code on the browser side, the other side does not refresh https://github.com/siyuan-note/siyuan/issues/8028
ginServer.Handle("POST", "/api/system/getNetwork", getNetwork) // 启动时获取网络设置,不能加鉴权
ginServer.Handle("GET", "/snippets/*filepath", serveSnippets)
// 需要鉴权
@ -63,6 +62,7 @@ func ServeAPI(ginServer *gin.Engine) {
ginServer.Handle("POST", "/api/system/checkUpdate", model.CheckAuth, checkUpdate)
ginServer.Handle("POST", "/api/system/exportLog", model.CheckAuth, exportLog)
ginServer.Handle("POST", "/api/system/getChangelog", model.CheckAuth, getChangelog)
ginServer.Handle("POST", "/api/system/getNetwork", model.CheckAuth, getNetwork)
ginServer.Handle("POST", "/api/storage/setLocalStorage", model.CheckAuth, model.CheckReadonly, setLocalStorage)
ginServer.Handle("POST", "/api/storage/getLocalStorage", model.CheckAuth, getLocalStorage)