Skip to content

Commit 52995e1

Browse files
committed
fix(phpstan): call to an undefined method Symfony\Component\TypeInfo\Type::getClassName()
1 parent 359a128 commit 52995e1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/JsonSchema/SchemaFactory.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -360,9 +360,9 @@ 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();
366366
}
367367

368368
$subSchemaInstance = new Schema($version);

0 commit comments

Comments
 (0)