Skip to content

Commit 6252fdc

Browse files
authored
Transfer namespace decorators for nested references
1 parent fa8e278 commit 6252fdc

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/PropertyProcessor/Property/ReferenceProcessor.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ public function process(string $propertyName, JsonSchema $propertySchema): Prope
3333

3434
if ($definition) {
3535
if ($this->schema->getClassPath() !== $definition->getSchema()->getClassPath() ||
36-
$this->schema->getClassName() !== $definition->getSchema()->getClassName()
36+
$this->schema->getClassName() !== $definition->getSchema()->getClassName() ||
37+
(
38+
$this->schema->getClassPath() === 'ExternalSchema' &&
39+
$definition->getSchema()->getClassPath() === 'ExternalSchema'
40+
)
3741
) {
3842
$this->schema->addNamespaceTransferDecorator(
3943
new SchemaNamespaceTransferDecorator($definition->getSchema())

0 commit comments

Comments
 (0)