{
public class FormUrlEncodedContent : ByteArrayContent
{
- public FormUrlEncodedContent(IEnumerable<KeyValuePair<string?, string?>> nameValueCollection)
+ public FormUrlEncodedContent(IEnumerable<KeyValuePair<string, string?>> nameValueCollection)
: base(GetContentByteArray(nameValueCollection))
{
Headers.ContentType = new MediaTypeHeaderValue("application/x-www-form-urlencoded");
}
- private static byte[] GetContentByteArray(IEnumerable<KeyValuePair<string?, string?>> nameValueCollection)
+ private static byte[] GetContentByteArray(IEnumerable<KeyValuePair<string, string?>> nameValueCollection)
{
if (nameValueCollection == null)
{
// Encode and concatenate data
StringBuilder builder = new StringBuilder();
- foreach (KeyValuePair<string?, string?> pair in nameValueCollection)
+ foreach (KeyValuePair<string, string?> pair in nameValueCollection)
{
if (builder.Length > 0)
{