Skip to content

Commit a78ddab

Browse files
authored
ReadErrorAsync() was missing a ConfigureAwait when called (#3275)
1 parent 9be3104 commit a78ddab

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/Elasticsearch.Net/Transport/Pipeline/ResponseBuilder.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77

88
namespace Elasticsearch.Net
99
{
10-
public class ResponseBuilder<TReturn>
10+
public class ResponseBuilder<TReturn>
1111
where TReturn : class
12-
12+
1313
{
1414
private const int BufferSize = 81920;
1515
private static readonly VoidResponse Void = new VoidResponse();
@@ -86,7 +86,7 @@ private void SetBody(ElasticsearchResponse<TReturn> response, Stream stream)
8686
if (this._requestData.CustomConverter != null) response.Body = this._requestData.CustomConverter(response, stream) as TReturn;
8787
else response.Body = this._requestData.ConnectionSettings.Serializer.Deserialize<TReturn>(stream);
8888
}
89-
if (response.AllowAllStatusCodes)
89+
if (response.AllowAllStatusCodes)
9090
ReadServerError(response, new MemoryStream(bytes), bytes);
9191
}
9292
else if (response.HttpStatusCode != null)
@@ -115,10 +115,10 @@ private async Task SetBodyAsync(ElasticsearchResponse<TReturn> response, Stream
115115
else response.Body = await this._requestData.ConnectionSettings.Serializer.DeserializeAsync<TReturn>(stream, this._cancellationToken).ConfigureAwait(false);
116116
}
117117
if (response.AllowAllStatusCodes)
118-
await ReadServerErrorAsync(response, new MemoryStream(bytes), bytes);
118+
await ReadServerErrorAsync(response, new MemoryStream(bytes), bytes).ConfigureAwait(false);
119119
}
120120
else if (response.HttpStatusCode != null)
121-
await ReadServerErrorAsync(response, stream, bytes);
121+
await ReadServerErrorAsync(response, stream, bytes).ConfigureAwait(false);
122122
}
123123
}
124124

0 commit comments

Comments
 (0)