Skip to content

Commit

Permalink
fix deprecation notice in PHP 8.4
Browse files Browse the repository at this point in the history
  • Loading branch information
mindplay-dk committed Aug 30, 2024
1 parent 14d3526 commit f923e6b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Dispatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
class Dispatcher implements MiddlewareInterface, RequestHandlerInterface
{
/**
* @var callable middleware resolver
* @var callable|null middleware resolver
*/
private $resolver;

Expand All @@ -32,7 +32,7 @@ class Dispatcher implements MiddlewareInterface, RequestHandlerInterface
*
* @throws InvalidArgumentException if an empty middleware stack was given
*/
public function __construct($stack, callable $resolver = null)
public function __construct($stack, ?callable $resolver = null)
{
if (count($stack) === 0) {
throw new InvalidArgumentException("an empty middleware stack was given");
Expand Down

0 comments on commit f923e6b

Please sign in to comment.