mirror of https://github.com/minio/minio.git
remove context deadline from Delete calls (#10901)
This commit is contained in:
parent
0745736e28
commit
80b8ce89a4
|
@ -323,10 +323,7 @@ func (client *storageRESTClient) DeleteVersion(ctx context.Context, volume, path
|
|||
return err
|
||||
}
|
||||
|
||||
tctx, cancel := context.WithTimeout(ctx, 5*time.Second)
|
||||
defer cancel()
|
||||
|
||||
respBody, err := client.call(tctx, storageRESTMethodDeleteVersion, values, &buffer, -1)
|
||||
respBody, err := client.call(ctx, storageRESTMethodDeleteVersion, values, &buffer, -1)
|
||||
defer http.DrainBody(respBody)
|
||||
return err
|
||||
}
|
||||
|
@ -506,9 +503,8 @@ func (client *storageRESTClient) Delete(ctx context.Context, volume string, path
|
|||
values.Set(storageRESTVolume, volume)
|
||||
values.Set(storageRESTFilePath, path)
|
||||
values.Set(storageRESTRecursive, strconv.FormatBool(recursive))
|
||||
tctx, cancel := context.WithTimeout(ctx, 5*time.Second)
|
||||
defer cancel()
|
||||
respBody, err := client.call(tctx, storageRESTMethodDeleteFile, values, nil, -1)
|
||||
|
||||
respBody, err := client.call(ctx, storageRESTMethodDeleteFile, values, nil, -1)
|
||||
defer http.DrainBody(respBody)
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue