We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad1e6bb commit 6f3e945Copy full SHA for 6f3e945
src/Rules/Comparison/ImpossibleCheckTypeHelper.php
@@ -70,7 +70,7 @@ public function findSpecifiedType(
70
if ($functionName === 'assert' && $argsCount >= 1) {
71
$arg = $node->getArgs()[0]->value;
72
$assertValues = ($this->treatPhpDocTypesAsCertain ? $scope->getType($arg) : $scope->getNativeType($arg))->getConstantScalarValues();
73
- if (count($assertValues) === 0 || !is_bool($assertValues[0])) {
+ if (count($assertValues) !== 1 || !is_bool($assertValues[0])) {
74
return null;
75
}
76
0 commit comments