Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit b03f0bd

Browse filesBrowse files
[Bridge\Doctrine] Fix BC with DI v3.4
1 parent 1cac0a0 commit b03f0bd
Copy full SHA for b03f0bd

File tree

Expand file treeCollapse file tree

1 file changed

+4
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-1
lines changed

‎src/Symfony/Bridge/Doctrine/ManagerRegistry.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/ManagerRegistry.php
+4-1Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,13 @@ protected function resetService($name)
4949
}
5050
$manager->setProxyInitializer(\Closure::bind(
5151
function (&$wrappedInstance, LazyLoadingInterface $manager) use ($name) {
52+
if (isset($this->normalizedIds[$normalizedId = strtolower($name)])) { // BC with DI v3.4
53+
$name = $this->normalizedIds[$normalizedId];
54+
}
5255
if (isset($this->aliases[$name])) {
5356
$name = $this->aliases[$name];
5457
}
55-
$method = $this->methodMap[$name] ?? 'get'.$name.'Service';
58+
$method = $this->methodMap[$name] ?? 'get'.strtr($name, $this->underscoreMap).'Service'; // BC with DI v3.4
5659
$wrappedInstance = $this->{$method}(false);
5760

5861
$manager->setProxyInitializer(null);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.