diff --git a/src/Message/CancelledFutureResponse.php b/src/Message/CancelledFutureResponse.php index 10d47144..59d85ee9 100644 --- a/src/Message/CancelledFutureResponse.php +++ b/src/Message/CancelledFutureResponse.php @@ -1,6 +1,7 @@ getMessage(), + $e->getRequest(), + $e->getResponse(), + $e + ); + } + return new self(new RejectedPromise($e)); } diff --git a/src/Message/MessageFactory.php b/src/Message/MessageFactory.php index 999727d1..c10c436c 100644 --- a/src/Message/MessageFactory.php +++ b/src/Message/MessageFactory.php @@ -325,9 +325,12 @@ class MessageFactory implements MessageFactoryInterface throw new Iae('events must be an array'); } - $this->attachListeners($request, $this->prepareListeners($value, - ['before', 'complete', 'error', 'progress'] - )); + $this->attachListeners($request, + $this->prepareListeners( + $value, + ['before', 'complete', 'error', 'progress', 'end'] + ) + ); break; case 'subscribers':