Closed RinkAttendant6 closed 6 years ago
Works as intended. zend-diactoros does not perform content negotiation. It is a responsibility of application, for example in zend-expressive: https://docs.zendframework.com/zend-expressive/features/helpers/body-parse/
The body of JSON requests is not being populated into the
parsedBody
property of theServerRequest
object when using\Zend\Diactoros\ServerRequestFactory::fromGlobals
. In fact, nothing appears to be parsed at all. Please see the following example:Request (only relevant parts included):
Code:
Result:
Expected result: