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 8119f8f commit 22a5f2aCopy full SHA for 22a5f2a
src/LiveComponent/src/Metadata/LiveComponentMetadataFactory.php
@@ -71,6 +71,15 @@ public function createPropMetadatas(\ReflectionClass $class): array
71
}
72
73
$type = $property->getType();
74
+ if ($type instanceof \ReflectionUnionType) {
75
+ throw new \LogicException(
76
+ sprintf(
77
+ 'Union types are not supported for LiveProps. You may want to change the type of property %s in %s.',
78
+ $property->getName(),
79
+ $property->getDeclaringClass()->getName()
80
+ )
81
+ );
82
+ }
83
$metadatas[$property->getName()] = new LivePropMetadata(
84
$property->getName(),
85
$attribute->newInstance(),
0 commit comments