Skip to content

Commit 9f46eef

Browse files
authored
fix(jsonschema): call to an undefined method Symfony\Component\TypeInfo\Type::getClassName() (#7685)
1 parent 1c6fae5 commit 9f46eef

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/JsonSchema/SchemaFactory.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -360,9 +360,11 @@ private function buildPropertySchema(Schema $schema, string $definitionName, str
360360

361361
if ($valueType instanceof ObjectType) {
362362
$className = $valueType->getClassName();
363-
} else {
363+
} elseif (($wrappedType = $valueType->getWrappedType()) instanceof ObjectType) {
364364
// GenericType
365-
$className = $valueType->getWrappedType()->getClassName();
365+
$className = $wrappedType->getClassName();
366+
} else {
367+
continue;
366368
}
367369

368370
$subSchemaInstance = new Schema($version);

0 commit comments

Comments
 (0)