Skip to content

Nullable does not work with OpenApi version 3.1.0 #89

@BendeRsay

Description

@BendeRsay

Hello. If you specify the property type ['null', 'string'], we get an error. Example:

new OA\Schema(
            schema: 'middleNameProperty',
            description: 'Patronymic of the user',
            type: ['null', 'string'],
            example: 'Ivanovich',
        ),

We get an error:

ByJG\ApiTools\Exception\NotMatchedException: Value of property '#/components/schemas/middleNameProperty' is null, but should be of type 'Array'

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions