[PHP] Handle non-required property as nullable
Created by: fMads
Description
When a property isn't required, it is not shown in Doc Block, that the getter can actually return "null". Also it is not shown in the setter, that "null" is a valid value
Swagger-codegen version
3.0.0-SNAPSHOT
Swagger declaration file content or url
/path
post:
parameters:
- in: body
required: true
name: objectName
schema:
type: object
required:
- requiredPropertyName
properties:
requiredPropertyName:
type: string
notRequiredPropertyName:
type: string
Suggest a fix/enhancement
Change returnType in Doc Block for getters to correctly show, that the returned value can be null (if the property is not required). Also shown in Doc Block for setters, that value can be null (if property is not required)