Browse Source

Remove extra stat object calls. (#405)

pull/412/head 3.1.12
Nathan Brown 5 years ago
committed by GitHub
parent
commit
51faca4e1f
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      Minio/ApiEndpoints/ObjectOperations.cs

4
Minio/ApiEndpoints/ObjectOperations.cs

@ -47,8 +47,6 @@ namespace Minio
/// <param name="cancellationToken">Optional cancellation token to cancel the operation</param>
public async Task GetObjectAsync(string bucketName, string objectName, Action<Stream> cb, ServerSideEncryption sse = null, CancellationToken cancellationToken = default(CancellationToken))
{
await StatObjectAsync(bucketName, objectName, sse: sse, cancellationToken: cancellationToken).ConfigureAwait(false);
var headers = new Dictionary<string, string>();
if (sse != null && sse.GetType().Equals(EncryptionType.SSE_C))
{
@ -86,8 +84,6 @@ namespace Minio
throw new ArgumentException("Length should be greater than zero", nameof(length));
}
await StatObjectAsync(bucketName, objectName, cancellationToken: cancellationToken).ConfigureAwait(false);
var headerMap = new Dictionary<string, string>();
if (length > 0)
{

Loading…
Cancel
Save