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 431ab3f commit 3eb8af3Copy full SHA for 3eb8af3
packages/mapper/src/CasterFactory.php
@@ -69,7 +69,7 @@ public function forProperty(PropertyReflector $property): ?Caster
69
public function forType(TypeReflector $type): ?Caster
70
{
71
foreach ($this->casters as [$for, $casterClass]) {
72
- if (is_string($for) && $type->matches($for) && ! \is_callable($for)) {
+ if (is_string($for) && $type->matches($for) && is_string($casterClass)) {
73
return get($casterClass);
74
}
75
0 commit comments