清理代码

This commit is contained in:
dragon
2025-09-25 11:57:23 +08:00
parent 9a425a057e
commit 92c0f73020
13 changed files with 92 additions and 74 deletions

View File

@@ -13,6 +13,7 @@ import (
"time"
"go.uber.org/zap"
"gopkg.d7z.net/gitea-pages/pkg/middleware/config"
"gopkg.in/yaml.v3"
"github.com/gobwas/glob"
@@ -30,13 +31,13 @@ type ServerMeta struct {
Domain string
client *http.Client
cache utils.KVConfig
cache config.KVConfig
ttl time.Duration
locker *utils.Locker
}
func NewServerMeta(client *http.Client, backend Backend, kv utils.KVConfig, domain string, ttl time.Duration) *ServerMeta {
func NewServerMeta(client *http.Client, backend Backend, kv config.KVConfig, domain string, ttl time.Duration) *ServerMeta {
return &ServerMeta{backend, domain, client, kv, ttl, utils.NewLocker()}
}