diff --git a/lib/Doctrine/ORM/PersistentCollection.php b/lib/Doctrine/ORM/PersistentCollection.php index fc2a00ba1..0732dd01c 100644 --- a/lib/Doctrine/ORM/PersistentCollection.php +++ b/lib/Doctrine/ORM/PersistentCollection.php @@ -471,9 +471,9 @@ final class PersistentCollection implements Collection if (!isset($this->doctrineCollectionCount)) { $this->doctrineCollectionCount = $this->em->getUnitOfWork() ->getCollectionPersister($this->association) - ->count($this) + $this->coll->count(); + ->count($this); } - return $this->doctrineCollectionCount; + return $this->doctrineCollectionCount + $this->coll->count(); } $this->initialize();