Skip to content

Commit b514893

Browse files
committed
Simplify
1 parent ba1ece5 commit b514893

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/Rules/Comparison/ImpossibleCheckTypeHelper.php

+1-5
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,7 @@ public function findSpecifiedType(
147147
foreach ($haystackArrayTypes as $haystackArrayType) {
148148
if ($haystackArrayType instanceof ConstantArrayType) {
149149
foreach ($haystackArrayType->getValueTypes() as $i => $haystackArrayValueType) {
150-
if ($haystackArrayValueType instanceof UnionType) {
151-
continue;
152-
}
153-
154-
if ($haystackArrayType->isOptionalKey($i)) {
150+
if ($haystackArrayValueType instanceof UnionType || $haystackArrayType->isOptionalKey($i)) {
155151
continue;
156152
}
157153

0 commit comments

Comments
 (0)