From c09ad7feaa8f8cf019dca82012a215243049bb4f Mon Sep 17 00:00:00 2001 From: jrfnl Date: Sat, 16 Mar 2024 19:57:34 +0100 Subject: [PATCH] Make PHP 8.4 implicit nullability fix compatible with PHP < 7.1 --- src/Manager.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Manager.php b/src/Manager.php index 6b852e0f..31d26ad3 100644 --- a/src/Manager.php +++ b/src/Manager.php @@ -17,9 +17,9 @@ class Manager * @throws Exception * @throws \Exception */ - public function run(?Settings $settings = null) + public function run($settings = null) { - $settings = $settings ?: new Settings; + $settings = ($settings instanceof Settings) ? $settings : new Settings(); $output = $this->output ?: $this->getDefaultOutput($settings); $phpExecutable = PhpExecutable::getPhpExecutable($settings->phpExecutable);