Skip to content

Commit

Permalink
remove workarounds for symfony 5
Browse files Browse the repository at this point in the history
  • Loading branch information
dbu committed Apr 6, 2024
1 parent af24cbb commit 5d94ca9
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 10 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
},
"conflict": {
"doctrine/phpcr-bundle": "<3.0",
"symfony/framework-bundle": "<5.4.6"
"symfony/framework-bundle": "<6.4"
},
"autoload": {
"psr-4": {
Expand Down
1 change: 0 additions & 1 deletion resources/config/dist/security.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
],
];


if (class_exists(\Symfony\Component\Security\Core\Security::class)) {
// Symfony 6 but not 7
$config['enable_authenticator_manager'] = true;
Expand Down
9 changes: 1 addition & 8 deletions src/Functional/BaseTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -143,14 +143,7 @@ protected function getDbManager(string $type)
));
}

$refl = new \ReflectionClass($className);
if (1 === $refl->getConstructor()->getNumberOfParameters()) {
// phpcr-bundle < 3
$dbManager = new $className(self::getContainer());
} else {
// phpcr-bundle >= 3
$dbManager = new $className(self::getContainer()->get('doctrine_phpcr'), self::getContainer()->get('doctrine_phpcr.initializer_manager'));
}
$dbManager = new $className(self::getContainer()->get('doctrine_phpcr'), self::getContainer()->get('doctrine_phpcr.initializer_manager'));

$this->dbManagers[$type] = $dbManager;

Expand Down

0 comments on commit 5d94ca9

Please sign in to comment.