Skip to content
Snippets Groups Projects
Commit 8d3ddd26 authored by Jan-Hendrik Willms's avatar Jan-Hendrik Willms
Browse files

fixes #3284

Closes #3284

Merge request studip/studip!2218
parent d2e68c55
No related branches found
No related tags found
No related merge requests found
...@@ -1521,6 +1521,13 @@ function studip_default_exception_handler($exception) { ...@@ -1521,6 +1521,13 @@ function studip_default_exception_handler($exception) {
try { try {
if (!isset($GLOBALS['user'])) {
$GLOBALS['user'] = new Seminar_User('nobody');
$GLOBALS['perm'] = new Seminar_Perm();
}
if (empty($_SESSION['_language'])) {
$_SESSION['_language'] = 'de_DE';
}
$args = compact('exception', 'status'); $args = compact('exception', 'status');
ob_start(); ob_start();
echo $GLOBALS['template_factory']->render($template, $args, $layout); echo $GLOBALS['template_factory']->render($template, $args, $layout);
......
...@@ -24,7 +24,11 @@ class CalendarNavigation extends Navigation ...@@ -24,7 +24,11 @@ class CalendarNavigation extends Navigation
parent::__construct(_('Planer')); parent::__construct(_('Planer'));
if (!$perm->have_perm('admin') && Config::get()->SCHEDULE_ENABLE) { if (
isset($perm)
&& !$perm->have_perm('admin')
&& Config::get()->SCHEDULE_ENABLE
) {
$planerinfo = _('Stundenplan'); $planerinfo = _('Stundenplan');
} else { } else {
$planerinfo = _('Termine'); $planerinfo = _('Termine');
......
...@@ -127,7 +127,7 @@ class StudipNavigation extends Navigation ...@@ -127,7 +127,7 @@ class StudipNavigation extends Navigation
} }
// admin page // admin page
if ($perm->have_perm('admin')) { if (isset($perm) && $perm->have_perm('admin')) {
$this->addSubNavigation('admin', new AdminNavigation()); $this->addSubNavigation('admin', new AdminNavigation());
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment