From 728a2dd56000bf2602a4cf5498f3043c79c72baf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Sun, 16 Apr 2023 13:47:32 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Container.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Container.php b/Container.php index 33b4e92..8f620d5 100644 --- a/Container.php +++ b/Container.php @@ -160,7 +160,7 @@ class Container implements ContainerInterface $object = self::configure($reflect->newInstanceArgs($construct), $config); $this->resolveProperties($reflect, $object); - if ($constructorHandler === null && method_exists($object, 'init')) { + if (method_exists($object, 'init') && $className !== 'Symfony\Component\Console\Application') { call_user_func([$object, 'init']); } return $object;