feat: support users to customize download ua
This commit is contained in:
@ -10,14 +10,12 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/Dreamacro/clash/component/tls"
|
||||
C "github.com/Dreamacro/clash/constant"
|
||||
"github.com/Dreamacro/clash/listener/inner"
|
||||
)
|
||||
|
||||
const (
|
||||
UA = "clash.meta"
|
||||
)
|
||||
|
||||
func HttpRequest(ctx context.Context, url, method string, header map[string][]string, body io.Reader) (*http.Response, error) {
|
||||
UA := C.UA
|
||||
method = strings.ToUpper(method)
|
||||
urlRes, err := URL.Parse(url)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user