diff --git a/lib/internal/Magento/Framework/App/Bootstrap.php b/lib/internal/Magento/Framework/App/Bootstrap.php index a5cfd46b7bf3e..5f126b38a0033 100644 --- a/lib/internal/Magento/Framework/App/Bootstrap.php +++ b/lib/internal/Magento/Framework/App/Bootstrap.php @@ -107,13 +107,6 @@ class Bootstrap */ private $factory; - /** - * Logger - * - * @var LoggerInterface - */ - private $logger; - /** * Static method so that client code does not have to create Object Manager Factory every time Bootstrap is called * @@ -214,7 +207,6 @@ public function __construct(ObjectManagerFactory $factory, $rootDir, array $init $this->rootDir = $rootDir; $this->server = $initParams; $this->objectManager = $this->factory->create($this->server); - $this->logger = $this->objectManager->create(LoggerInterface::class); } /** @@ -267,7 +259,7 @@ public function run(AppInterface $application) \Magento\Framework\Profiler::stop('magento'); } catch (\Exception $e) { \Magento\Framework\Profiler::stop('magento'); - $this->logger->error($e->getMessage()); + $this->objectManager->get(LoggerInterface::class)->error($e); if (!$application->catchException($this, $e)) { throw $e; }