api-platform / core

The server component of API Platform: hypermedia and GraphQL APIs in minutes
https://api-platform.com
MIT License
2.45k stars 876 forks source link

Output when use Processor #6499

Closed expondo closed 1 month ago

expondo commented 3 months ago

API Platform version(s) affected: 3.3.11

Description

I have ApiResource endpoint defined on DTO with Post(). In t hi endpoint i use Procesor, and method process return void. Before update to 3.3.11 in this case (version 3.2.12) this endpoint returned the same input, but after update to 3.3.11 the same endpoint are returning "null". I already fixed that, bit this is little strange change in that update.

How to reproduce

processor like @implements ProcessorInterface<MyDTO, void> will return MyDTO in version 3.2.12 will retur n"null" in 3.3.11

Possible Solution

Additional Context

soyuka commented 3 months ago

It's an expected behavior returning void is the same as null we don't want to guess what output you want, maybe that we can add something to the changelog in that regard.

stale[bot] commented 1 month ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.