Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Config] Fix using null values with config builders#45789
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
| { | ||
| private$priority; | ||
| private$color; | ||
| private$_usedProperties = []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
we don't use underscores in property names
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
@nicolas-grekas This is to avoid collision with configuration proprieties (->scalarNode('used_properties')), same as with_extraKeys.
Sorry, I accidentally resolved this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Got it, thanks for the explanation.
| unset($value['scalar_node']); | ||
| } | ||
| if (isset($value['scalar_node_with_default'])) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
shouldn't this usearray_key_exists to allow passingnull ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
@stof Yep, missed that one, tnx. Fixedhttps://github.com/symfony/symfony/compare/e214761c573ecc980b5d1b5e3c4dff12f8a6933d..1264225f4ebc535deec491737b70d9bc1d84dc98
e214761 to1264225Comparenicolas-grekas commentedMar 22, 2022
Thank you@HypeMC. |
The generated config builders will no longer discard
nullvalues.