Skip to content

Commit 0c814b4

Browse files
committed
Display a simple error if the translation option does not work #146
1 parent 20c3298 commit 0c814b4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

featherbb/routes.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,8 @@
222222
}
223223

224224
// Display a simple error page that does not require heavy user-specific methods like permissions
225-
if (method_exists($e, 'isSimpleError') && $e->isSimpleError()) {
225+
if (method_exists($e, 'isSimpleError') && $e->isSimpleError()
226+
|| !function_exists('__')) {
226227
if (ob_get_contents()) {
227228
ob_end_clean();
228229
}
@@ -245,7 +246,6 @@
245246
$error['html'] = $e->displayHtml();
246247
}
247248

248-
249249
return View::setPageInfo([
250250
'title' => [\FeatherBB\Core\Utils::escape(ForumSettings::get('o_board_title')), __('Error')],
251251
'msg' => $error['message'],

0 commit comments

Comments
 (0)