mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
DDC-1432: $em->remove($entity) on entity that uses @Id + @ManyToOne generates fatal at UnitOfWork #1794
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 (Oct 18, 2011).
Originally assigned to: @beberlei on GitHub.
Jira issue originally created by user hypno:
$em->remove($entity) on entity that uses @Id + @ManyToOne generates fatal at UnitOfWork
PHP Catchable fatal error: Object of class User could not be converted to string in /path/to/Doctrine/ORM/UnitOfWork.php on line 2166
Probably because it tries to use UserData primary key properties directly and not detecting that its actually an association.
@doctrinebot commented on GitHub (Nov 18, 2011):
Comment created by @beberlei:
Line 2166 in version 2.1.2 is a docblock comment.
Can you specifiy this more and potentially add the stacktrace when this warning occurs (xdebug)?
@doctrinebot commented on GitHub (Mar 14, 2012):
Comment created by @beberlei:
No feedback given.
@doctrinebot commented on GitHub (Mar 14, 2012):
Issue was closed with resolution "Incomplete"
@doctrinebot commented on GitHub (Jun 21, 2012):
Comment created by bill'o:
just got the same issue with a composite key on an association table, the line is 2242 in UnitOfWork.php