diff --git a/src/Doctrine/DoctrineHelper.php b/src/Doctrine/DoctrineHelper.php index 21b4005fa..d0906ce0a 100644 --- a/src/Doctrine/DoctrineHelper.php +++ b/src/Doctrine/DoctrineHelper.php @@ -24,7 +24,6 @@ use Doctrine\Persistence\Mapping\Driver\MappingDriver; use Doctrine\Persistence\Mapping\Driver\MappingDriverChain; use Doctrine\Persistence\Mapping\MappingException as PersistenceMappingException; -use Doctrine\Persistence\Mapping\StaticReflectionService; use Symfony\Bundle\MakerBundle\Util\ClassNameDetails; use Symfony\Component\Uid\Ulid; use Symfony\Component\Uid\Uuid; @@ -175,9 +174,6 @@ public function getMetadata(?string $classOrNamespace = null, bool $disconnected $loaded = $this->isInstanceOf($cmf, AbstractClassMetadataFactory::class) ? $cmf->getLoadedMetadata() : []; } - // Set the reflection service that was used in the now removed DisconnectedClassMetadataFactory::class - $cmf->setReflectionService(new StaticReflectionService()); - foreach ($loaded as $m) { $cmf->setMetadataFor($m->getName(), $m); }