zend-expressive 3.0.0alpha9
Added
- #562 adds the class
Zend\Expressive\Response\ServerRequestErrorResponseGenerator
, and maps it to theZend\Expressive\Container\ServerRequestErrorResponseGeneratorFactory
. The class generates an error response when an exeption occurs producing a server request instance, and can be optionally templated.
Changed
-
#568 updates the zendframework/zend-stratigility dependency to require at least 3.0.0alpha4.
-
#568 updates the
ErrorHandlerFactory
to pull thePsr\Http\Message\ResponseInterface
service, which returns a factory capable of returning a response instance, and passes it to theZend\Stratigility\Middleware\ErrorHandler
instance it creates, as that class changes in 3.0.0alpha4 such that it now expects a factory instead of an instance. -
#562 modifies the
Zend\Expressive\Container\RequestHandlerRunnerFactory
to depend on theZend\Expressive\Response\ServerRequestErrorResponseGenerator
service instead of theZend\Expressive\SERVER_REQUEST_ERROR_RESPONSE_GENERATOR
virtual service. -
#562 extracts most logic from
Zend\Expressive\Middleware\ErrorResponseGenerator
to a new trait,Zend\Expressive\Response\ErrorResponseGeneratorTrait
. A trait was used as the classes consuming it are from different namespaces, and thus different inheritance trees. The trait is used by both theErrorResponseGenerator
and the newServerRequestErrorResponseGenerator
.
Deprecated
- Nothing.
Removed
- #562 removes the constant
Zend\Expressive\SERVER_REQUEST_ERROR_RESPONSE_GENERATOR
. It was only used internally previously.
Fixed
- Nothing.