[DDC-1392] Merge for not initialized entity proxy object with set ID fails Created: 23/Sep/11 Updated: 16/Jan/15 Resolved: 25/Sep/11
|Project:||Doctrine 2 - ORM|
|Reporter:||Aigars Gedroics||Assignee:||Benjamin Eberlei|
Problem is that UnitOfWork::doMerge() calls ClassMetadata::getIdentifierValues() for the entity but that function doesn't have case for not initialized proxy. It just reads the Id properties from the object's reflection.
It should load the proxy or get the ID stored inside the proxy object or doMerge must initialize it maybe.
|Comment by Aigars Gedroics [ 23/Sep/11 ]|
I have taken the DDC353 test as the base for this test case.
|Comment by Benjamin Eberlei [ 25/Sep/11 ]|
|Comment by Aigars Gedroics [ 26/Sep/11 ]|
I would put the changes inside the method getIdentifierValues not before it's execution.
Isn't it plausible that it is called with not initialized proxy from somewhere else?