[ai-statistics] update logic of api extraction (#2927)

This commit is contained in:
rinfx
2025-09-16 19:51:18 +08:00
committed by GitHub
parent 42a74449f7
commit 7e9f98d14b

View File

@@ -150,7 +150,7 @@ func getAPIName() (string, error) {
return "-", err
} else {
parts := strings.Split(string(raw), "@")
if len(parts) != 5 {
if len(parts) < 3 {
return "-", errors.New("not api type")
} else {
return strings.Join(parts[:3], "@"), nil