-
-
Notifications
You must be signed in to change notification settings - Fork 364
[LiveComponent] Add support for interfaces while (de)hydrating a Doctrine entity #2834
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
base: 2.x
Are you sure you want to change the base?
Conversation
…iased to an entity Doctrine have the feature to use interface aliased to a concrete entity class. This PR propose a small modification to ensure that is will also supported by the doctrine hydrator
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.
Thanks for your first contribution :)
src/LiveComponent/src/Hydration/DoctrineEntityHydrationExtension.php
Outdated
Show resolved
Hide resolved
// if ($om = $registry->getManagerForClass($class)) { | ||
// return self::ensureManagedObject($om, $class); | ||
// } |
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.
This should either be removed or kept
src/LiveComponent/src/Hydration/DoctrineEntityHydrationExtension.php
Outdated
Show resolved
Hide resolved
Making tests
The last commit provides some tests. |
Doctrine have the feature to use interface aliased to a concrete entity class.
This PR propose a small modification to ensure that is will also supported by the doctrine hydrator