From 6506d1dd8823102b4e04275162f5bd59c4f588d9 Mon Sep 17 00:00:00 2001 From: Jaume Date: Thu, 28 Nov 2024 19:06:43 +0100 Subject: [PATCH] Fix deprecation warnings in PHP 8.4 --- src/DotEnv.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/DotEnv.php b/src/DotEnv.php index 63abfb7..338edaa 100644 --- a/src/DotEnv.php +++ b/src/DotEnv.php @@ -26,7 +26,7 @@ class DotEnv */ protected array $processors = []; - public function __construct(string $path, array $processors = null) + public function __construct(string $path, ?array $processors = null) { if (!file_exists($path)) { throw new InvalidArgumentException(sprintf('%s does not exist', $path)); @@ -66,7 +66,7 @@ public function load(): void } } - private function setProcessors(array $processors = null): void + private function setProcessors(?array $processors = null): void { /** * Fill with default processors