Dingo API Response object loses existing response HTTP Version
Open
- Dominant language
- PHP
- Stars
- 9.4k
- Forks
- 1.3k
- PR merge metrics
- No merged PRs in 30d
Description
The Dingo Response.php method makeFromExisting fails to clone the ProtocolVersion from the existing Illuminate/Symfony Response object, so if a previous middleware has changed it (i.e. to version 1.1), this gets lost.
Workaround is to establish an event listener for one of the Response morph events and set the protocol version on the response via the event handler, but it seems like makeFromExisting should be setting the ProtocolVersion property on the new response object to match the old response object.
Contributor guide
Assessment
This issue has not been assessed yet.