Ensured symfony/console stays in v4.1.4, since the next one throws a lot of phpstan errors

This commit is contained in:
Alejandro Celaya
2018-09-30 11:02:01 +02:00
parent 0813df6b29
commit 3282bfd03b
11 changed files with 53 additions and 42 deletions

View File

@@ -10,10 +10,11 @@ use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Style\SymfonyStyle;
use Zend\I18n\Translator\TranslatorInterface;
use function sprintf;
class DisableKeyCommand extends Command
{
const NAME = 'api-key:disable';
public const NAME = 'api-key:disable';
/**
* @var ApiKeyServiceInterface
@@ -31,14 +32,14 @@ class DisableKeyCommand extends Command
parent::__construct();
}
public function configure()
protected function configure(): void
{
$this->setName(self::NAME)
->setDescription($this->translator->translate('Disables an API key.'))
->addArgument('apiKey', InputArgument::REQUIRED, $this->translator->translate('The API key to disable'));
}
public function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output): void
{
$apiKey = $input->getArgument('apiKey');
$io = new SymfonyStyle($input, $output);