ai优化,删除未使用代码,提取重复代码。

This commit is contained in:
2026-08-12 11:12:23 +08:00
parent 043bf8773b
commit 60869ec214
10 changed files with 108 additions and 201 deletions
+1 -5
View File
@@ -4,7 +4,6 @@ import (
"net/http"
"strconv"
"goblog/config"
"goblog/database"
"goblog/models"
@@ -21,10 +20,7 @@ const (
// GetSettings 获取站点基础设置(管理员)
func GetSettings(c *gin.Context) {
cfg := config.GetGlobalConfig()
if cfg == nil {
cfg = config.Load()
}
cfg := getConfig()
opts, err := models.GetOptionsByUser(database.DB, 0)
if err != nil {