mirror of
https://github.com/linux-do/new-api.git
synced 2025-11-13 01:23:41 +08:00
fix: add missing upstreamModelName
This commit is contained in:
@@ -34,6 +34,7 @@ func GenRelayInfo(c *gin.Context) *RelayInfo {
|
||||
userId := c.GetInt("id")
|
||||
group := c.GetString("group")
|
||||
tokenUnlimited := c.GetBool("token_unlimited_quota")
|
||||
upstreamModelName := c.GetString("model_name")
|
||||
startTime := time.Now()
|
||||
|
||||
apiType := constant.ChannelType2APIType(channelType)
|
||||
@@ -52,6 +53,7 @@ func GenRelayInfo(c *gin.Context) *RelayInfo {
|
||||
ApiType: apiType,
|
||||
ApiVersion: c.GetString("api_version"),
|
||||
ApiKey: strings.TrimPrefix(c.Request.Header.Get("Authorization"), "Bearer "),
|
||||
UpstreamModelName: upstreamModelName,
|
||||
}
|
||||
if info.BaseUrl == "" {
|
||||
info.BaseUrl = common.ChannelBaseURLs[channelType]
|
||||
|
||||
Reference in New Issue
Block a user