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 d76de92 commit c5c325fCopy full SHA for c5c325f
1 file changed
rules/TypeDeclaration/NodeAnalyzer/CallTypesResolver.php
@@ -226,9 +226,10 @@ private function isArrayMixedMixedType(Type $type): bool
226
if (! $type instanceof ArrayType) {
227
if ($type instanceof UnionType) {
228
$types = $type->getTypes();
229
- $type = $this->typeFactory->createMixedPassedOrUnionType($types);
+ $checkedType = $this->typeFactory->createMixedPassedOrUnionType($types);
230
231
- if ($type instanceof UnionType) {
+ if ($checkedType instanceof UnionType) {
232
+ $types = $checkedType->getTypes();
233
if (count($types) !== 2) {
234
return false;
235
}
0 commit comments