mirror of
https://github.com/gospider007/requests.git
synced 2025-12-24 13:57:52 +08:00
sync
This commit is contained in:
@@ -76,7 +76,7 @@ func (obj *Client) SetProxy(proxyUrl string) (err error) {
|
||||
|
||||
// Modify the proxy method of the client
|
||||
func (obj *Client) SetGetProxy(getProxy func(ctx context.Context, url *url.URL) (string, error)) {
|
||||
obj.transport.setGetProxy(getProxy)
|
||||
obj.option.GetProxy = getProxy
|
||||
}
|
||||
|
||||
// Modifying the client's proxy
|
||||
@@ -93,7 +93,7 @@ func (obj *Client) SetProxys(proxyUrls []string) (err error) {
|
||||
|
||||
// Modify the proxy method of the client
|
||||
func (obj *Client) SetGetProxys(getProxys func(ctx context.Context, url *url.URL) ([]string, error)) {
|
||||
obj.transport.setGetProxys(getProxys)
|
||||
obj.option.GetProxys = getProxys
|
||||
}
|
||||
|
||||
// Close idle connections. If the connection is in use, wait until it ends before closing
|
||||
|
||||
Reference in New Issue
Block a user