Skip to content
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

[Transaction] Remove @ORM\Entity #40

Merged
merged 1 commit into from
Nov 16, 2016
Merged

[Transaction] Remove @ORM\Entity #40

merged 1 commit into from
Nov 16, 2016

Conversation

alexandre-abrioux
Copy link
Contributor

@alexandre-abrioux alexandre-abrioux commented Nov 16, 2016

Following Doctrine's documentation (http://docs.doctrine-project.org/en/latest/reference/inheritance-mapping.html)

a mapped superclass cannot be an entity

otherwise extending the class leads to errors such as described here : http://stackoverflow.com/questions/21536634/doctrine-query-crashing
There is hence an architecture choice to be made : either keep the @ORM\MappedSuperclass annotation or remove it.
I personally think this is the bundle's user responsibility to extend the class should he need to persist the object, this is why I removed the @ORM\Entity annotation.

@paulandrieux paulandrieux merged commit bbf43d9 into Troopers:master Nov 16, 2016
@paulandrieux
Copy link
Member

You are right, thank you !

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.

2 participants