Skip to content

Commit 5fef96e

Browse files
committed
Make nullable parameters explicity nullable for PHP 8.4
1 parent e71eb1a commit 5fef96e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Process.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ class Process extends EventEmitter
112112
* @param null|array $fds File descriptors to allocate for this process (or null = default STDIO streams)
113113
* @throws \LogicException On windows or when proc_open() is not installed
114114
*/
115-
public function __construct($cmd, $cwd = null, array $env = null, array $fds = null)
115+
public function __construct($cmd, $cwd = null, ?array $env = null, ?array $fds = null)
116116
{
117117
if (!\function_exists('proc_open')) {
118118
throw new \LogicException('The Process class relies on proc_open(), which is not available on your PHP installation.');
@@ -164,7 +164,7 @@ public function __construct($cmd, $cwd = null, array $env = null, array $fds = n
164164
* @param float $interval Interval to periodically monitor process state (seconds)
165165
* @throws \RuntimeException If the process is already running or fails to start
166166
*/
167-
public function start(LoopInterface $loop = null, $interval = 0.1)
167+
public function start(?LoopInterface $loop = null, $interval = 0.1)
168168
{
169169
if ($this->isRunning()) {
170170
throw new \RuntimeException('Process is already running');

0 commit comments

Comments
 (0)