Add files via upload

This commit is contained in:
公明
2026-08-15 02:19:19 +08:00
committed by GitHub
parent 6fc0004ac3
commit 409e75f15a
97 changed files with 42068 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
package handler
import (
"strings"
"cyberstrike-ai/internal/config"
)
// effectiveProjectID 请求/队列显式项目优先,否则使用 config.project.default_project_id。
func effectiveProjectID(cfg *config.Config, explicit string) string {
if pid := strings.TrimSpace(explicit); pid != "" {
return pid
}
if cfg != nil {
return strings.TrimSpace(cfg.Project.DefaultProjectID)
}
return ""
}