diff --git a/src/Http/HttpClientContextStrata.php b/src/Http/HttpClientContextStrata.php index e59ed9c..28e0e0f 100644 --- a/src/Http/HttpClientContextStrata.php +++ b/src/Http/HttpClientContextStrata.php @@ -30,7 +30,7 @@ trait HttpClientContextStrata { use ContextStrata; - public function __construct($message = null, $code = 0, Throwable $previous = null) + public function __construct(?string $message = null, ?int $code = 0, ?Throwable $previous = null) { parent::__construct($message ?? $this->suggestErrorMessage(), $code ?? 0, $previous); } diff --git a/src/Http/HttpServerContextStrata.php b/src/Http/HttpServerContextStrata.php index fff2b49..d3e46db 100644 --- a/src/Http/HttpServerContextStrata.php +++ b/src/Http/HttpServerContextStrata.php @@ -30,7 +30,7 @@ trait HttpServerContextStrata { use ContextStrata; - public function __construct($message = null, $code = 0, Throwable $previous = null) + public function __construct(?string $message = null, ?int $code = 0, ?Throwable $previous = null) { parent::__construct($message ?? $this->suggestErrorMessage(), $code ?? 0, $previous); } diff --git a/src/LogicException.php b/src/LogicException.php index 8034929..ee574ca 100644 --- a/src/LogicException.php +++ b/src/LogicException.php @@ -18,7 +18,7 @@ class LogicException extends \LogicException implements { use ContextStrata; - public function __construct($message = null, $code = 0, Throwable $previous = null) + public function __construct(?string $message = null, ?int $code = 0, ?Throwable $previous = null) { parent::__construct($message ?? '', $code ?? 0, $previous); } diff --git a/src/RuntimeException.php b/src/RuntimeException.php index c25bb5a..3847b31 100644 --- a/src/RuntimeException.php +++ b/src/RuntimeException.php @@ -18,7 +18,7 @@ class RuntimeException extends \RuntimeException implements { use ContextStrata; - public function __construct($message = null, $code = 0, Throwable $previous = null) + public function __construct(?string $message = null, ?int $code = 0, ?Throwable $previous = null) { parent::__construct($message ?? '', $code ?? 0, $previous); }