Skip to content

Commit

Permalink
fixup! rename use of getStaticType() to getType()
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasVotruba committed Oct 7, 2021
1 parent 89086c0 commit 4b80044
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/NodeTypeResolver/NodeTypeResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,10 @@ public function isObjectType(Node $node, ObjectType $requiredObjectType): bool
public function resolve(Node $node): Type
{
if ($node instanceof Ternary) {
return $this->resolveTernaryType($node);
$ternaryType = $this->resolveTernaryType($node);
if (! $ternaryType instanceof MixedType) {
return $ternaryType;
}
}

if ($node instanceof Coalesce) {
Expand Down

0 comments on commit 4b80044

Please sign in to comment.