mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
DDC-3582: Nested embeddables are instantiated with the wrong class #4403
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @doctrinebot on GitHub (Feb 22, 2015).
Originally assigned to: @beberlei on GitHub.
Jira issue originally created by user jankramer:
Consider the example where an entity contains an embeddable, that itself contains 2 different embeddables. So Entity -> Embeddable 1 -> (Embeddable 2, Embeddable 3). In this case, Embeddable1 will be instantiated as an Embeddable2 for some reason.
Please see
5e6b02a0fafor a test that demonstrates this and currently fails.I looked at the code in the ReflectionEmbeddedProperty, and noticed that 'embeddedClass' was recently changed from 'class'. If I change it back, this test passes, but then the ReflectionEmbeddedPropertyTest fails on the scenario for abstract classes. @ocramius, I saw you were the author on that change, could you please take a look? Thanks!
@doctrinebot commented on GitHub (Feb 22, 2015):
Comment created by jankramer:
Closing this as I can't seem to reproduce this issue anymore.
@doctrinebot commented on GitHub (Feb 24, 2015):
Comment created by jankramer:
Now able to reproduce this issue, updated the description.
@doctrinebot commented on GitHub (Feb 24, 2015):
Comment created by @ocramius:
[~jankramer] please send a PR with that diff
@doctrinebot commented on GitHub (Feb 24, 2015):
Comment created by jankramer:
@ocramius See https://github.com/doctrine/doctrine2/pull/1311
@doctrinebot commented on GitHub (Feb 27, 2015):
Comment created by @doctrinebot:
A related Github Pull-Request [GH-1311] was assigned:
https://github.com/doctrine/doctrine2/pull/1311
@doctrinebot commented on GitHub (Feb 27, 2015):
Comment created by @doctrinebot:
A related Github Pull-Request [GH-1311] was merged:
https://github.com/doctrine/doctrine2/pull/1311