Skip to content

Commit

Permalink
Fix never return union type wrong condition
Browse files Browse the repository at this point in the history
Fix never return union type wrong condition

Related vimeo#8624
  • Loading branch information
kkmuffme committed Dec 29, 2022
1 parent 5bfb87c commit ac8f892
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Psalm/Type.php
Expand Up @@ -643,7 +643,7 @@ public static function combineUnionTypes(
$combined_type->ignore_falsable_issues = true;
}

if ($type_1->explicit_never && $type_2->explicit_never) {
if ($type_1->explicit_never || $type_2->explicit_never) {
$combined_type->explicit_never = true;
}

Expand Down

0 comments on commit ac8f892

Please sign in to comment.