minor #35387 [Console] Fix "Input" typehints (PatchRanger)
This PR was merged into the 5.0 branch.
Discussion
----------
[Console] Fix "Input" typehints
| Q | A
| ------------- | ---
| Branch? | 5.0
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix #35385
| License | MIT
Commits
-------
75dbaf0cc5
Fix #35385: Fix Console typehint
This commit is contained in:
commit
67fd73a312
@ -104,7 +104,7 @@ abstract class Input implements InputInterface, StreamableInputInterface
|
|||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function getArgument($name)
|
public function getArgument(string $name)
|
||||||
{
|
{
|
||||||
if (!$this->definition->hasArgument($name)) {
|
if (!$this->definition->hasArgument($name)) {
|
||||||
throw new InvalidArgumentException(sprintf('The "%s" argument does not exist.', $name));
|
throw new InvalidArgumentException(sprintf('The "%s" argument does not exist.', $name));
|
||||||
@ -116,7 +116,7 @@ abstract class Input implements InputInterface, StreamableInputInterface
|
|||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function setArgument($name, $value)
|
public function setArgument(string $name, $value)
|
||||||
{
|
{
|
||||||
if (!$this->definition->hasArgument($name)) {
|
if (!$this->definition->hasArgument($name)) {
|
||||||
throw new InvalidArgumentException(sprintf('The "%s" argument does not exist.', $name));
|
throw new InvalidArgumentException(sprintf('The "%s" argument does not exist.', $name));
|
||||||
|
Reference in New Issue
Block a user