소스 검색

feat: playground token name

1808837298@qq.com 1 년 전
부모
커밋
e298f2e5a4
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      controller/relay.go

+ 1 - 0
controller/relay.go

@@ -73,6 +73,7 @@ func Playground(c *gin.Context) {
 	} else {
 		c.Set("group", group)
 	}
+	c.Set("token_name", "playground-"+group)
 	channel, err := model.CacheGetRandomSatisfiedChannel(group, playgroundRequest.Model, 0)
 	if err != nil {
 		message := fmt.Sprintf("当前分组 %s 下对于模型 %s 无可用渠道", group, playgroundRequest.Model)