Skip to content

Commit 40841c8

Browse files
tvlooyfabpot
authored andcommitted
Fix docs
symfony documentation tells people to pass null, and it is the default, but the method docs don't allow it so static analyzers complain about it (spotted by phan)
1 parent a700b87 commit 40841c8

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Command/Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ public function addArgument($name, $mode = null, $description = '', $default = n
388388
* Adds an option.
389389
*
390390
* @param string $name The option name
391-
* @param string|array $shortcut The shortcuts, can be null, a string of shortcuts delimited by | or an array of shortcuts
391+
* @param string|array|null $shortcut The shortcuts, can be null, a string of shortcuts delimited by | or an array of shortcuts
392392
* @param int|null $mode The option mode: One of the InputOption::VALUE_* constants
393393
* @param string $description A description text
394394
* @param string|string[]|int|bool|null $default The default value (must be null for InputOption::VALUE_NONE)

Input/InputOption.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class InputOption
3434

3535
/**
3636
* @param string $name The option name
37-
* @param string|array $shortcut The shortcuts, can be null, a string of shortcuts delimited by | or an array of shortcuts
37+
* @param string|array|null $shortcut The shortcuts, can be null, a string of shortcuts delimited by | or an array of shortcuts
3838
* @param int|null $mode The option mode: One of the VALUE_* constants
3939
* @param string $description A description text
4040
* @param string|string[]|int|bool|null $default The default value (must be null for self::VALUE_NONE)
@@ -89,7 +89,7 @@ public function __construct($name, $shortcut = null, $mode = null, $description
8989
/**
9090
* Returns the option shortcut.
9191
*
92-
* @return string The shortcut
92+
* @return string|null The shortcut
9393
*/
9494
public function getShortcut()
9595
{

0 commit comments

Comments
 (0)