diff --git a/lib/Doctrine/ORM/EntityManager.php b/lib/Doctrine/ORM/EntityManager.php index cdd178baf..305d5c8b3 100644 --- a/lib/Doctrine/ORM/EntityManager.php +++ b/lib/Doctrine/ORM/EntityManager.php @@ -725,6 +725,6 @@ class EntityManager implements ObjectManager throw new \InvalidArgumentException("Invalid argument: " . $conn); } - return new EntityManager($conn, $config, $conn->getEventManager()); + return new self($conn, $config, $conn->getEventManager()); } }