summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorIgor Scheller <igor.scheller@igorshp.de>2018-08-29 22:05:38 +0200
committerIgor Scheller <igor.scheller@igorshp.de>2018-08-29 23:46:32 +0200
commit3a1164164791edbe30c7247b98585474867dd968 (patch)
tree0776fc89332d46d415344f5accdb9a4d32521485 /src
parentacfe72cb9155ca08bd5799d0dde331702e25e9ce (diff)
Updated LegacyMiddleware to use Translator class
Diffstat (limited to 'src')
-rw-r--r--src/Middleware/LegacyMiddleware.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Middleware/LegacyMiddleware.php b/src/Middleware/LegacyMiddleware.php
index 78132815..233f66b2 100644
--- a/src/Middleware/LegacyMiddleware.php
+++ b/src/Middleware/LegacyMiddleware.php
@@ -83,9 +83,12 @@ class LegacyMiddleware implements MiddlewareInterface
}
if (empty($title) and empty($content)) {
+ /** @var Translator $translator */
+ $translator = $this->container->get('translator');
+
$page = 404;
- $title = _('Page not found');
- $content = _('This page could not be found or you don\'t have permission to view it. You probably have to sign in or register in order to gain access!');
+ $title = $translator->translate('Page not found');
+ $content = $translator->translate('This page could not be found or you don\'t have permission to view it. You probably have to sign in or register in order to gain access!');
}
return $this->renderPage($page, $title, $content);