bug fix
This commit is contained in:
parent
a8eed30db5
commit
4e17fee681
4
curl.go
4
curl.go
@ -1736,12 +1736,12 @@ func NewSimpleRequestWithContextWithClient(ctx context.Context, client *http.Cli
|
|||||||
}
|
}
|
||||||
|
|
||||||
func NewRequestWithContextWithClient(ctx context.Context, client *http.Client, uri string, method string, opts ...RequestOpt) (*Request, error) {
|
func NewRequestWithContextWithClient(ctx context.Context, client *http.Client, uri string, method string, opts ...RequestOpt) (*Request, error) {
|
||||||
req, err := newRequest(context.Background(), uri, method, opts...)
|
req, err := newRequest(ctx, uri, method, opts...)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
req.rawClient = client
|
req.rawClient = client
|
||||||
req.SetDoRawClient(true)
|
req.SetDoRawClient(true)
|
||||||
req.SetDoRawTransport(true)
|
req.SetDoRawTransport(true)
|
||||||
return nil, err
|
return req, err
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user