Open mjgabriel opened 5 years ago
Found the following though:
Example 1
return Negotiate.WithStatusCode(HttpStatusCode.NotFound)
Returns no CORS headers when no model.
Example 2
return Negotiate
.WithModel("Your request is bad. :(")
.WithStatusCode(HttpStatusCode.BadRequest)
Returns CORS headers with model.
Example 3
return Negotiate.WithStatusCode(HttpStatusCode.NoContent)
Returns CORS headers (no .WithModel
)
Hi Nancy Version: 1.4.4 .NET Framework: 4.7.1
Just curious why CORS headers aren't included when I use something like
Negotiate.WithStatusCode(HttpStatusCode.NotFound
?If using content negotiation, are you responsible for outputting everything that may be needed?
Negotiate.WithModel(model)
includes the CORS headers without any additional code.I know this isn't the format requested for issues. Just looking to be pointed any documentation I may have missed or misunderstood.
Thanks