Skip to content
Snippets Groups Projects
Commit e5d23219 authored by David Siegfried's avatar David Siegfried Committed by Jan-Hendrik Willms
Browse files

prevent php-warnings in CourseNavigation, fixes #4771

Closes #4771

Merge request !3560
parent a57302ac
No related branches found
No related tags found
No related merge requests found
......@@ -71,16 +71,18 @@ class CourseNavigation extends Navigation
}
}
foreach ($navigations as $key => $nav) {
if (
$this->range instanceof Institute
|| Seminar_Perm::get()->have_studip_perm($found->getVisibilityPermission(), $this->range->id)
) {
if (isset($found->metadata['displayname'])) {
$nav->setTitle($found->getDisplayname());
}
if ($found) {
foreach ($navigations as $key => $nav) {
if (
$this->range instanceof Institute
|| Seminar_Perm::get()->have_studip_perm($found->getVisibilityPermission(), $this->range->id)
) {
if (isset($found->metadata['displayname'])) {
$nav->setTitle($found->getDisplayname());
}
$this->insertSubNavigation($key, $nav, $where);
$this->insertSubNavigation($key, $nav, $where);
}
}
}
}
......
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