diff --git a/src/Illuminate/Foundation/Console/AboutCommand.php b/src/Illuminate/Foundation/Console/AboutCommand.php index 3b3c2cd958e8..23d2b23b631a 100644 --- a/src/Illuminate/Foundation/Console/AboutCommand.php +++ b/src/Illuminate/Foundation/Console/AboutCommand.php @@ -273,8 +273,8 @@ protected function sections() * Materialize a function that formats a given value for CLI or JSON output. * * @param mixed $value - * @param (\Closure():(mixed))|null $console - * @param (\Closure():(mixed))|null $json + * @param (\Closure(mixed):(mixed))|null $console + * @param (\Closure(mixed):(mixed))|null $json * @return \Closure(bool):mixed */ public static function format($value, Closure $console = null, Closure $json = null) diff --git a/types/Foundation/AboutCommand.php b/types/Foundation/AboutCommand.php new file mode 100644 index 000000000000..61718f36914a --- /dev/null +++ b/types/Foundation/AboutCommand.php @@ -0,0 +1,11 @@ + $value ? 'ENABLED' : 'OFF'); + +assertType('Closure(bool): mixed', $format); +assertType('mixed', $format(false)); +assertType('mixed', $format(true));