[BUG][PHP] non-null, negative value cannot be serialized (empty array, false, etc)
Created by: mvehar
Description
non-null, negative value cannot be serialized (empty array, false, etc). problem is IF statement in generated controllers (request?$this->serialize(...)).
openapi-generator version
3.3.4, same problem on 4.0.0
Command line used for generation
PHP symphony templates
Steps to reproduce
Generate pet store, implement listPets with returning empty array, check response -> its empty body, not serialized empty array
Related issues/PRs
/
Suggest a fix/enhancement
Preparing pull request. ($request !== null ? $this->serialize.. )