#1587: using delete() for 1:n-relations does not update main object
--------------------------------------+-------------------------------------
Reporter: floriank | Owner: romanb
Type: defect | Status: new
Priority: major | Milestone: 1.0.4
Component: Record | Version: 1.0.3
Keywords: deleting related records | Has_test: 1
Mystatus: Pending Core Response | Has_patch: 0
--------------------------------------+-------------------------------------
When deleting a related 1:n-record via delete() (as described in the
documentation at 6.1.4) the _references-array of the main model is not
refreshed properly. If you for example have a user with three email-
addresses (see the testcase in method testDelete()), delete one of them
and count his email-addresses, count() will return 3 instead of 2.
Another issue i noticed is that i cannot refresh() a model if i call
delete() for a related record. This only works if i put the delete in a
transaction (see methods testDeleteWithoutTransaction() and
testDeleteWithTransaction() testcases).
--
Ticket URL: <http://trac.doctrine-project.org/ticket/1587>
Doctrine <http://www.phpdoctrine.org>
PHP Doctrine Object Relational Mapper
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"doctrine-svn" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.co.uk/group/doctrine-svn?hl=en-GB
-~----------~----~----~----~------~----~------~--~---