chore: remove helper & util subpackage for relay

This commit is contained in:
JustSong
2024-04-06 01:50:12 +08:00
parent 24ed170e7b
commit f586ae0ad8
19 changed files with 221 additions and 215 deletions

View File

@@ -4,8 +4,8 @@ import (
"errors"
"fmt"
"github.com/gin-gonic/gin"
"github.com/songquanpeng/one-api/relay/client"
"github.com/songquanpeng/one-api/relay/meta"
"github.com/songquanpeng/one-api/relay/util"
"io"
"net/http"
)
@@ -39,7 +39,7 @@ func DoRequestHelper(a Adaptor, c *gin.Context, meta *meta.Meta, requestBody io.
}
func DoRequest(c *gin.Context, req *http.Request) (*http.Response, error) {
resp, err := util.HTTPClient.Do(req)
resp, err := client.HTTPClient.Do(req)
if err != nil {
return nil, err
}