Skip to content

Commit 84e57d3

Browse files
Remove redundant cast
Remove redundant cast needed from when net5.0 was a TFM.
1 parent 0f32a07 commit 84e57d3

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/HttpClientInterception/HttpRequestInterceptionBuilderExtensions.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -181,9 +181,7 @@ public static HttpRequestInterceptionBuilder WithFormContent(
181181

182182
async Task<byte[]> ContentFactoryAsync()
183183
{
184-
// The cast is to make nullability match for .NET 5.0.
185-
// See https://github.com/dotnet/runtime/issues/38494.
186-
using var content = new FormUrlEncodedContent((IEnumerable<KeyValuePair<string?, string?>>)parameters);
184+
using var content = new FormUrlEncodedContent(parameters);
187185
return await content.ReadAsByteArrayAsync().ConfigureAwait(false);
188186
}
189187

0 commit comments

Comments
 (0)