Skip to content

Cannot add a header "Content-Type" in v107 #1713

@PusheadSG

Description

@PusheadSG

Describe the bug
Header "Content-Type" is not getting added to the request

To Reproduce
Make any RestSharp request, and .AddHeader("Content-Type", "blivelsnotch") to the request. Run the request and examine the data being sent. There will be no "Content-Type" header sent, no matter what value you enter. Change the spelling of "Content-Type" to "ContentType" and the header gets added.

Expected behavior
.AddHeader("Content-Type", "value") should add a header of "Content-Type" to the request.

Desktop (please complete the following information):

  • OS: Windows 10
  • .NET 5
  • Version 107.1.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions