Skip to content

Enable nullable on Kestrel generated code #28792

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Dec 27, 2020

Conversation

JamesNK
Copy link
Member

@JamesNK JamesNK commented Dec 22, 2020

Addresses #5680

@ghost ghost added the area-servers label Dec 22, 2020
@JamesNK JamesNK changed the title Enable nullable on generated code Enable nullable on Kestrel generated code Dec 22, 2020
@@ -104,33 +106,50 @@ private object ExtraFeatureGet(Type key)
return null;
}

private void ExtraFeatureSet(Type key, object value)
private void ExtraFeatureSet(Type key, object? value)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Previously calling ExtraFeatureSet with a null value would leave a null entry in MaybeExtra. These entries would still be returned when foreaching over feature collection.

Now null extra features are completely removed.

@JamesNK JamesNK merged commit 1902aa2 into master Dec 27, 2020
@JamesNK JamesNK deleted the jamesnk/nullable-generatedcode branch December 27, 2020 01:11
@amcasey amcasey added area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlewares area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlewares area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants