Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Commit

Permalink
MvcEvent target should be changed back to the application on finish
Browse files Browse the repository at this point in the history
  • Loading branch information
Roy van Kaathoven committed Mar 20, 2012
1 parent c1d855e commit 4c710dc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions library/Zend/Mvc/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ public function run()
if ($result->stopped()) {
$response = $result->last();
if ($response instanceof Response) {
$event->setTarget($this);
$events->trigger('finish', $event);
return $response;
}
Expand All @@ -253,6 +254,7 @@ public function run()
// Complete response
$response = $result->last();
if ($response instanceof Response) {
$event->setTarget($this);
$events->trigger('finish', $event);
return $response;
}
Expand All @@ -275,6 +277,7 @@ public function run()
protected function completeRequest(MvcEvent $event)
{
$events = $this->events();
$event->setTarget($this);
$events->trigger('render', $event);
$events->trigger('finish', $event);
return $event->getResponse();
Expand Down

0 comments on commit 4c710dc

Please sign in to comment.