Fix 404 error page

This commit is contained in:
badsuricate
2013-10-23 23:25:41 +02:00
parent 4660992d75
commit b26c3216c5

View File

@@ -8,6 +8,7 @@ use \Symfony\Component\EventDispatcher\EventDispatcherInterface;
use \Smarty;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpKernel\Exception\HttpException;
use Thelia\Core\Template\ParserInterface;
use Thelia\Core\Template\Smarty\AbstractSmartyPlugin;
@@ -139,7 +140,7 @@ class SmartyParser extends Smarty implements ParserInterface
try {
$templateFile = $this->getTemplateFilePath();
} catch (\RuntimeException $e) {
return new Response($e->getMessage(), "404");
return new Response($this->render(\Thelia\Model\ConfigQuery::getPageNotFoundView()), "404");
}
return $this->render($templateFile);