Skip to content

Commit

Permalink
Minor changes for error.twig
Browse files Browse the repository at this point in the history
Signed-off-by: Alxarafe <info@alxarafe.com>
  • Loading branch information
Alxarafe committed Feb 16, 2019
1 parent 9f4b72a commit 9571eee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions resources/templates/error.twig
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
#}
{% extends "index.twig" %}

{% block title %}{{ lang.trans('error') }}{% endblock %}
{% block title %}{{ title }}{% endblock %}

{% block body %}
{% if main.title is empty %}<h1>{{ lang.trans('error') }}</h1>{% endif %}
{% if main.title is empty %}<h1>{{ title }}</h1>{% endif %}
<div class="row">
<div class="col-sm-12">
{{ msg }}
Expand Down
6 changes: 3 additions & 3 deletions src/Core/BootStrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -244,18 +244,18 @@ public function run()
$controller = new $controllerName($this->container);
$controller->{$method}();
} else {
$msg = 'Method not available';
$msg = $this->translator->trans('method-not-available');
}
} else {
$msg = 'Route not found';
$msg = $this->translator->trans('route-not-found');
}

$this->render->setTemplate('error');
$vars = [
'ctrl' => $this,
'title' => $this->translator->trans('error'),
'msg' => $msg,
];
$this->render->render($vars);
return;
}
}

0 comments on commit 9571eee

Please sign in to comment.