diff --git a/src/DumpRecorder/MultiDumpHandler.php b/src/DumpRecorder/MultiDumpHandler.php index dd341f3..93c08c6 100644 --- a/src/DumpRecorder/MultiDumpHandler.php +++ b/src/DumpRecorder/MultiDumpHandler.php @@ -14,7 +14,7 @@ public function dump($value) } } - public function addHandler(callable $callable = null): self + public function addHandler(?callable $callable = null): self { $this->handlers[] = $callable; diff --git a/src/Payloads/CachePayload.php b/src/Payloads/CachePayload.php index bcc92b3..c77adde 100644 --- a/src/Payloads/CachePayload.php +++ b/src/Payloads/CachePayload.php @@ -22,7 +22,7 @@ class CachePayload extends Payload /** @var int|null */ protected $expirationInSeconds; - public function __construct(string $type, string $key, $tags, $value = null, int $expirationInSeconds = null) + public function __construct(string $type, string $key, $tags, $value = null, ?int $expirationInSeconds = null) { $this->type = $type; diff --git a/src/Payloads/MailablePayload.php b/src/Payloads/MailablePayload.php index 69b7623..bc548e4 100644 --- a/src/Payloads/MailablePayload.php +++ b/src/Payloads/MailablePayload.php @@ -19,7 +19,7 @@ public static function forMailable(Mailable $mailable) return new self(self::renderMailable($mailable), $mailable); } - public function __construct(string $html, Mailable $mailable = null) + public function __construct(string $html, ?Mailable $mailable = null) { $this->html = $html; diff --git a/src/Ray.php b/src/Ray.php index b1331e2..7f4ac17 100644 --- a/src/Ray.php +++ b/src/Ray.php @@ -44,7 +44,7 @@ class Ray extends BaseRay { - public function __construct(Settings $settings, Client $client = null, string $uuid = null) + public function __construct(Settings $settings, ?Client $client = null, ?string $uuid = null) { // persist the enabled setting across multiple instantiations $enabled = static::$enabled; @@ -487,7 +487,7 @@ public function stopShowingHttpClientRequests(): self return $this; } - protected function handleWatcherCallable(Watcher $watcher, Closure $callable = null) + protected function handleWatcherCallable(Watcher $watcher, ?Closure $callable = null) { $rayProxy = new RayProxy();