Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Commit

Permalink
Bug fix: getting view service fails for notFound routes
Browse files Browse the repository at this point in the history
  • Loading branch information
mkorkmaz committed Jun 20, 2017
1 parent 8989e33 commit 4aeaf4e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion src/Foundation/App.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ public function __construct(
Router $router,
ContainerInterface $container
) {

$this->config = $config;
$this->route = $router->getRoute();
$this->container = $container;
Expand Down
2 changes: 1 addition & 1 deletion src/Foundation/Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ public function notFound($status = 404, $returnType = 'html', $message = 'Not Fo
if ($returnType == 'json') {
$this->body = ['status' => $status, 'message' => $message];
} else {
$this->useView($this->container->get('view'));
$this->useView($this->container->get(ViewInterface::class));
$notFoundTemplate = '_404.twig';
$this->contentType = $returnType;
$this->body = $this->view->render(
Expand Down

0 comments on commit 4aeaf4e

Please sign in to comment.