From 00e54c79647c292c2091feb3ecae56190ca9aad9 Mon Sep 17 00:00:00 2001 From: Abel Date: Fri, 22 Aug 2025 07:22:40 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20php8.4=20=E4=B8=8B?= =?UTF-8?q?=EF=BC=9AImplicitly=20marking=20parameter=20$env=20as=20nullabl?= =?UTF-8?q?e=20is=20deprecated=20php8.4=20=E4=B8=8B=E4=BD=BF=E7=94=A8?= =?UTF-8?q?=E9=98=9F=E5=88=97=E5=91=BD=E4=BB=A4=EF=BC=9Aphp=20think=20queu?= =?UTF-8?q?e:listen=20=E7=AD=89=E4=BC=9A=E8=A7=A6=E5=8F=91=E8=BF=99?= =?UTF-8?q?=E4=B8=AA=E9=94=99=E8=AF=AF=20```bash=20[think\exception\ErrorE?= =?UTF-8?q?xception]=20think\Process::=5F=5Fconstruct():=20Implicitly=20ma?= =?UTF-8?q?rking=20parameter=20$env=20as=20nullable=20is=20deprecated,=20t?= =?UTF-8?q?he=20explicit=20nullable=20type=20must=20be=20used=20instead=20?= =?UTF-8?q?```?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 相关参考:https://php.watch/versions/8.4/implicitly-marking-parameter-type-nullable-deprecated Signed-off-by: Abel --- library/think/Process.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/Process.php b/library/think/Process.php index 6f3faa31..7348be47 100644 --- a/library/think/Process.php +++ b/library/think/Process.php @@ -123,7 +123,7 @@ class Process * @throws \RuntimeException * @api */ - public function __construct($commandline, $cwd = null, array $env = null, $input = null, $timeout = 60, array $options = []) + public function __construct($commandline, $cwd = null, ?array $env = null, $input = null, $timeout = 60, array $options = []) { if (!function_exists('proc_open')) { throw new \RuntimeException('The Process class relies on proc_open, which is not available on your PHP installation.'); -- Gitee