diff --git a/composer.json b/composer.json index 9c2f076..5d4082b 100644 --- a/composer.json +++ b/composer.json @@ -28,7 +28,7 @@ "require": { "php": ">=8.1", "react/event-loop": "^1.2", - "react/promise": "^3.0 || ^2.8 || ^1.2.1" + "react/promise": "^3.2 || ^2.8 || ^1.2.1" }, "require-dev": { "phpstan/phpstan": "1.10.39", diff --git a/src/FiberFactory.php b/src/FiberFactory.php index 93480e6..ee90818 100644 --- a/src/FiberFactory.php +++ b/src/FiberFactory.php @@ -22,7 +22,7 @@ public static function create(): FiberInterface return (self::factory())(); } - public static function factory(\Closure $factory = null): \Closure + public static function factory(?\Closure $factory = null): \Closure { if ($factory !== null) { self::$factory = $factory;