Skip to content

Commit

Permalink
feature #39118 [DoctrineBridge] Require doctrine/persistence 2 (greg0…
Browse files Browse the repository at this point in the history
…ire)

This PR was merged into the 5.2 branch.

Discussion
----------

[DoctrineBridge] Require doctrine/persistence 2

| Q             | A
| ------------- | ---
| Branch       | 5.x
| Bug fix      | no
| New feature  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | n/a
| License       | MIT
| Doc PR        | n/a

This allows us to remove autoload calls that are necessary for the
persistence 1 backwards-compatibility layer to work.

This is a follow up of #35728

Commits
-------

574a184 Require doctrine/persistence 2
  • Loading branch information
fabpot committed Nov 27, 2020
2 parents 7378b0b + 574a184 commit ac25e8c
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 11 deletions.
4 changes: 2 additions & 2 deletions composer.json
Expand Up @@ -19,7 +19,7 @@
"php": ">=7.2.5",
"ext-xml": "*",
"doctrine/event-manager": "~1.0",
"doctrine/persistence": "^1.3|^2",
"doctrine/persistence": "^2",
"twig/twig": "^2.10|^3.0",
"psr/cache": "~1.0",
"psr/container": "^1.0",
Expand Down Expand Up @@ -116,7 +116,7 @@
"doctrine/collections": "~1.0",
"doctrine/data-fixtures": "^1.1",
"doctrine/dbal": "^2.10|^3.0",
"doctrine/orm": "~2.4,>=2.4.5",
"doctrine/orm": "^2.7.3",
"doctrine/doctrine-bundle": "^2.0",
"guzzlehttp/promises": "^1.3.1",
"masterminds/html5": "^2.6",
Expand Down
2 changes: 0 additions & 2 deletions src/Symfony/Bridge/Doctrine/Form/Type/DoctrineType.php
Expand Up @@ -269,5 +269,3 @@ private function getCachedEntityLoader(ObjectManager $manager, $queryBuilder, st
return $this->entityLoaders[$hash] ?? ($this->entityLoaders[$hash] = $this->getLoader($manager, $queryBuilder, $class));
}
}

interface_exists(ObjectManager::class);
2 changes: 0 additions & 2 deletions src/Symfony/Bridge/Doctrine/Form/Type/EntityType.php
Expand Up @@ -96,5 +96,3 @@ private function parameterToArray(Parameter $parameter): array
return [$parameter->getName(), $parameter->getType(), $parameter->getValue()];
}
}

interface_exists(ObjectManager::class);
Expand Up @@ -153,6 +153,3 @@ private function getClassMetadata(): ClassMetadata
return $this->getObjectManager()->getClassMetadata($this->classOrAlias);
}
}

interface_exists(ObjectManager::class);
interface_exists(ObjectRepository::class);
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/Doctrine/composer.json
Expand Up @@ -18,7 +18,7 @@
"require": {
"php": ">=7.2.5",
"doctrine/event-manager": "~1.0",
"doctrine/persistence": "^1.3|^2",
"doctrine/persistence": "^2",
"symfony/polyfill-ctype": "~1.8",
"symfony/polyfill-mbstring": "~1.0",
"symfony/polyfill-php80": "^1.15",
Expand Down Expand Up @@ -48,7 +48,7 @@
"doctrine/collections": "~1.0",
"doctrine/data-fixtures": "^1.1",
"doctrine/dbal": "^2.10|^3.0",
"doctrine/orm": "^2.6.3"
"doctrine/orm": "^2.7.3"
},
"conflict": {
"doctrine/dbal": "<2.10",
Expand Down

0 comments on commit ac25e8c

Please sign in to comment.