diff --git a/src/Hydra/JsonSchema/SchemaFactory.php b/src/Hydra/JsonSchema/SchemaFactory.php index d5a5feb079e..f1df478c407 100644 --- a/src/Hydra/JsonSchema/SchemaFactory.php +++ b/src/Hydra/JsonSchema/SchemaFactory.php @@ -123,7 +123,7 @@ public function buildSchema(string $className, string $format = 'jsonld', string 'variable' => ['type' => 'string'], 'property' => [ 'nullable' => true, - 'anyOf' => [['type' => 'string'], ['type' => 'null']], + 'type' => ['string', 'null'], ], 'required' => ['type' => 'boolean'], ],