Fix #35385: Fix Console typehint

This commit is contained in:
Dmitry Danilson 2020-01-19 18:13:19 +07:00
parent b4a63f925f
commit 75dbaf0cc5

View File

@ -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));