Skip to content

Conversation

@tillig
Copy link
Member

@tillig tillig commented Sep 15, 2024

Resolves #1427 by removing the exception check for null when registering a property value using WithProperty(Expression, Value).

As part of this, I found that the base ConstantParameter class used by both constructor and property parameters does allow null as a value to be injected but not all the derived classes had the proper nullable type annotations. I updated the derived classes to consistently annotate the value as allowing null.

Copy link
Member

@alistairjevans alistairjevans left a comment

Choose a reason for hiding this comment

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

Looks good! 🚢

@tillig tillig merged commit e4f1bc6 into develop Sep 21, 2024
@tillig tillig deleted the feature/with-property-consistency branch September 21, 2024 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inconsistent behavior of different RegistrationExtensions.WithProperty overloads regarding nullable properties

3 participants