File tree Expand file tree Collapse file tree 1 file changed +1
-2
lines changed Expand file tree Collapse file tree 1 file changed +1
-2
lines changed Original file line number Diff line number Diff line change @@ -87,13 +87,12 @@ public function findSpecifiedType(
87
87
return null ;
88
88
}
89
89
90
- $ constantArrays = $ haystackType ->getConstantArrays ();
91
90
$ needleType = $ scope ->getType ($ node ->getArgs ()[0 ]->value );
92
91
$ valueType = $ haystackType ->getIterableValueType ();
93
92
$ constantNeedleTypesCount = count (TypeUtils::getConstantScalars ($ needleType ));
94
93
$ constantHaystackTypesCount = count (TypeUtils::getConstantScalars ($ valueType ));
95
94
$ isNeedleSupertype = $ needleType ->isSuperTypeOf ($ valueType );
96
- if (count ( $ constantArrays ) === 0 ) {
95
+ if ($ haystackType -> isConstantArray ()-> no () ) {
97
96
if ($ haystackType ->isIterableAtLeastOnce ()->yes ()) {
98
97
if ($ constantNeedleTypesCount === 1 && $ constantHaystackTypesCount === 1 ) {
99
98
if ($ isNeedleSupertype ->yes ()) {
You can’t perform that action at this time.
0 commit comments