summaryrefslogtreecommitdiff
path: root/app/Core/Controller/Runner.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2016-05-25 21:28:33 -0400
committerFrederic Guillot <fred@kanboard.net>2016-05-25 21:28:33 -0400
commit872dc79dbd8b04424520e32675a6e0dcb6ed44bc (patch)
tree46b08d77e39c09fd415e9c943931db0a03de7c99 /app/Core/Controller/Runner.php
parent74a84a28e34f3c1c38631fb80cc74ab589a44298 (diff)
Do not execute controller if the response is already sent
Diffstat (limited to 'app/Core/Controller/Runner.php')
-rw-r--r--app/Core/Controller/Runner.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/Core/Controller/Runner.php b/app/Core/Controller/Runner.php
index b973c098..8353cf69 100644
--- a/app/Core/Controller/Runner.php
+++ b/app/Core/Controller/Runner.php
@@ -26,7 +26,10 @@ class Runner extends Base
{
try {
$this->executeMiddleware();
- $this->executeController();
+
+ if (!$this->response->isResponseAlreadySent()) {
+ $this->executeController();
+ }
} catch (PageNotFoundException $e) {
$controllerObject = new AppController($this->container);
$controllerObject->notFound($e->hasLayout());