Skip to content

Commit e8a05a0

Browse files
committed
[DependencyInjection] Optimize AutowireRequiredMethodsPass
1 parent 95f0098 commit e8a05a0

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/Symfony/Component/DependencyInjection/Compiler/AutowireRequiredMethodsPass.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,10 @@ protected function processValue(mixed $value, bool $isRoot = false): mixed
5757
}
5858
break;
5959
}
60-
try {
61-
$r = $r->getPrototype();
62-
} catch (\ReflectionException) {
63-
break; // method has no prototype
60+
if (!$r->hasPrototype()) {
61+
break;
6462
}
63+
$r = $r->getPrototype();
6564
}
6665
}
6766

0 commit comments

Comments
 (0)