Skip to content

Commit 83a6298

Browse files
committed
Update CallableType.php
1 parent 4ee9651 commit 83a6298

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/Type/CallableType.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,10 @@ public function isSubTypeOf(Type $otherType): IsSuperTypeOfResult
204204
return $otherType->isSuperTypeOf($this);
205205
}
206206

207-
return (new IsSuperTypeOfResult($otherType->isCallable(), []))
208-
->and($otherType instanceof self ? IsSuperTypeOfResult::createYes() : IsSuperTypeOfResult::createMaybe());
207+
return new IsSuperTypeOfResult(
208+
$otherType->isCallable()->and($otherType instanceof self ? TrinaryLogic::createYes() : TrinaryLogic::createMaybe()),
209+
[]
210+
);
209211
}
210212

211213
public function isAcceptedBy(Type $acceptingType, bool $strictTypes): AcceptsResult

0 commit comments

Comments
 (0)