mirror of
https://github.com/rclone/rclone.git
synced 2024-11-25 08:58:26 +08:00
rest: call the Signer with the mutex unlocked
This enables the signer to adjust rest parameters and call rest again if necessary.
This commit is contained in:
parent
65071599a2
commit
14e93bfd8a
|
@ -269,7 +269,9 @@ func (api *Client) Call(ctx context.Context, opts *Opts) (resp *http.Response, e
|
|||
c = api.c
|
||||
}
|
||||
if api.signer != nil {
|
||||
api.mu.RUnlock()
|
||||
err = api.signer(req)
|
||||
api.mu.RLock()
|
||||
if err != nil {
|
||||
return nil, errors.Wrap(err, "signer failed")
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user