Commit 945ef23
committed
[php Symfony] fix return type for non json/xml api
This fixes the generated returned type of controller methods for
endpoint with a response declared like
content:
text/plain:
schema:
type: <boolean|string|integer|number>
or for
content:
image/png:
schema:
type: string
format: binary
Without this commit the generated method *had to* return a value that
matched "array|object|null", which does not work in this case.
This commit makes it possible to return the proper type.1 parent 36217ad commit 945ef23
1 file changed
Lines changed: 20 additions & 2 deletions
File tree
- modules/openapi-generator/src/main/java/org/openapitools/codegen/languages
Lines changed: 20 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
417 | 417 | | |
418 | 418 | | |
419 | 419 | | |
420 | | - | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
421 | 425 | | |
| 426 | + | |
| 427 | + | |
422 | 428 | | |
423 | | - | |
| 429 | + | |
424 | 430 | | |
425 | 431 | | |
426 | 432 | | |
| |||
438 | 444 | | |
439 | 445 | | |
440 | 446 | | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
441 | 459 | | |
442 | 460 | | |
443 | 461 | | |
| |||
0 commit comments