Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.6k
[Serializer] AdddefaultType
toDiscriminatorMap
#59828
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
Uh oh!
There was an error while loading.Please reload this page.
83f1ca5
to828656f
Comparesrc/Symfony/Component/Serializer/Tests/Attribute/DiscriminatorMapTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Serializer/Tests/Normalizer/AbstractObjectNormalizerTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Serializer/Tests/Normalizer/AbstractObjectNormalizerTest.phpShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Serializer/Mapping/ClassDiscriminatorMapping.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
828656f
toc03064a
ComparedefaultValue
toDiscriminatorMap
defaultType
toDiscriminatorMap
Thanks for the review@mtarld! |
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.
With minor comments 🙂
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Serializer/Tests/Attribute/DiscriminatorMapTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
c03064a
to9d089bd
CompareThank you@alanpoulain. |
cb93a4f
intosymfony:7.3Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
I thought it would be nice to have a default type value for the discriminator map of the serializer.
For instance with this configuration:
It would deserialize to an
Article
with this data:And to a
Video
with this: