diff --git a/lib/Doctrine/ORM/EntityManager.php b/lib/Doctrine/ORM/EntityManager.php index 8c42298a4..229884dea 100644 --- a/lib/Doctrine/ORM/EntityManager.php +++ b/lib/Doctrine/ORM/EntityManager.php @@ -315,7 +315,7 @@ class EntityManager if ( ! is_array($identifier)) { $identifier = array($class->identifier[0] => $identifier); } - $entity = $this->_proxyFactory->getProxy($entityName, $identifier); + $entity = $this->_proxyFactory->getProxy($class->name, $identifier); $this->_unitOfWork->registerManaged($entity, $identifier, array()); return $entity;