We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b8a871d commit bb3da26Copy full SHA for bb3da26
src/Type/UnionTypeHelper.php
@@ -109,7 +109,10 @@ public static function sortTypes(array $types): array
109
return self::compareStrings($a->describe(VerbosityLevel::value()), $b->describe(VerbosityLevel::value()));
110
}
111
112
- if ($a->isCallable()->yes() && $b->isCallable()->yes()) {
+ if (
113
+ ($a instanceof CallableType || $a instanceof ClosureType)
114
+ && ($b instanceof CallableType || $b instanceof ClosureType)
115
+ ) {
116
117
118
0 commit comments