Skip to content

Commit 3f680e4

Browse files
committed
try to fix build
1 parent dcd31dc commit 3f680e4

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Php/ComposerPhpVersionFactory.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
use function end;
1414
use function is_array;
1515
use function is_file;
16+
use function is_int;
1617
use function is_string;
1718
use function sprintf;
1819

@@ -33,6 +34,10 @@ public function __construct(
3334
bool $bleedingEdge,
3435
)
3536
{
37+
if (is_int($phpVersion)) {
38+
return;
39+
}
40+
3641
if (is_array($phpVersion)) {
3742
if ($phpVersion['max'] < $phpVersion['min']) {
3843
throw new ShouldNotHappenException('Invalid PHP version range: phpVersion.max should be greater or equal to phpVersion.min.');

0 commit comments

Comments
 (0)