Skip to content

Commit 6a74309

Browse files
committed
fix: make phpstan think the right way
I edit the value manually so tell phpstan it is dynamic
1 parent 0b31b3c commit 6a74309

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Console/Command/VersionCommand.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,11 +84,13 @@ protected function execute(InputInterface $input, OutputInterface $output)
8484
return 0;
8585
}
8686
if ($input->getOption('text')) {
87+
/** @var bool $isDev */
88+
$isDev = $data['is_dev_version'];
8789
$output->writeln('Version: ' . $data['version']);
8890
$output->writeln('Version-major: ' . $data['major']);
8991
$output->writeln('Version-minor: ' . $data['minor']);
9092
$output->writeln('Version-patch: ' . $data['patch']);
91-
$output->writeln('Version-is-dev: ' . ($data['is_dev_version'] ? 'yes' : 'no'));
93+
$output->writeln('Version-is-dev: ' . ($isDev ? 'yes' : 'no'));
9294
$output->writeln('License: ' . $data['license']);
9395
$isPhar = $data['phar_metadata'] !== null;
9496
$output->writeln('Phar-detected: ' . ($isPhar ? 'yes' : 'no'));

0 commit comments

Comments
 (0)