mirror of
https://github.com/linux-do/new-api.git
synced 2025-11-08 23:23:42 +08:00
fix: 修复流模式错误扣费的问题 (close #95)
This commit is contained in:
@@ -127,8 +127,8 @@ func OpenaiHandler(c *gin.Context, resp *http.Response, promptTokens int, model
|
||||
}
|
||||
if textResponse.Error.Type != "" {
|
||||
return &dto.OpenAIErrorWithStatusCode{
|
||||
OpenAIError: textResponse.Error,
|
||||
StatusCode: resp.StatusCode,
|
||||
Error: textResponse.Error,
|
||||
StatusCode: resp.StatusCode,
|
||||
}, nil
|
||||
}
|
||||
// Reset response body
|
||||
|
||||
Reference in New Issue
Block a user