优化结构

This commit is contained in:
Yvan
2026-08-28 15:37:40 +08:00
parent a4ed3a02df
commit 9b1daaf3f6
17 changed files with 100 additions and 64 deletions
+1 -1
View File
@@ -65,7 +65,7 @@ func NewGinEngineWithRuntime(runtime *config.Store, access *systemservice.Access
if snapshot != nil && snapshot.Admin != nil && snapshot.Admin.App != nil {
env = strings.ToLower(strings.TrimSpace(snapshot.Admin.App.Env))
}
if env != "production" && env != "prod" && env != "live" && env != "staging" {
if env == "" || env == "development" || env == "dev" || env == "test" || env == "local" {
registerSwagger(engine, prefix, version, logger)
}
staticfiles.Register(engine, runtime)