Fix error message for invalid API key format

This commit is contained in:
IcedTangerine
2025-10-18 00:13:28 +08:00
committed by GitHub
parent 8965fc49c9
commit 6a24c37c0e

View File

@@ -107,7 +107,7 @@ var responseFormatToEncodingMap = map[string]string{
func parseVolcengineAuth(apiKey string) (appID, token string, err error) {
parts := strings.Split(apiKey, "|")
if len(parts) != 2 {
return "", "", errors.New("invalid api key format, expected: appid:access_token")
return "", "", errors.New("invalid api key format, expected: appid|access_token")
}
return parts[0], parts[1], nil
}