diff options
| author | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2026-02-13 13:39:58 +0100 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2026-02-13 13:39:58 +0100 |
| commit | 1cc8ffd08cc1bbf98cf0b4819cf67762ebf5faa1 (patch) | |
| tree | 6d9aa3d451706793e7780d567018a16de7c1f4d9 /lib/plugins/engine/PluginEngine.php | |
| parent | 9439556848fbc126bd4d4436df2d0dbe22e7b796 (diff) | |
fix access to free courses and restore navigation item, fixes #6248
Closes #6248
Merge request studip/studip!4730
Diffstat (limited to 'lib/plugins/engine/PluginEngine.php')
| -rw-r--r-- | lib/plugins/engine/PluginEngine.php | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/lib/plugins/engine/PluginEngine.php b/lib/plugins/engine/PluginEngine.php index 599b4f2..5c7bad5 100644 --- a/lib/plugins/engine/PluginEngine.php +++ b/lib/plugins/engine/PluginEngine.php @@ -43,6 +43,7 @@ class PluginEngine self::getPlugins(HomepagePlugin::class); $context_id = Context::getId(); + // load course plugins if ($context_id) { $modules = self::getPlugins(StudipModule::class, $context_id); @@ -51,14 +52,7 @@ class PluginEngine foreach ($modules as $module) { $tabs = $module->getTabNavigation($context_id); - if (!$tabs || !$navigation) { - continue; - } - - $has_perm = $GLOBALS['perm']->get_studip_perm($context_id); - $is_core = $module instanceof CoreOverview; - - if ($has_perm || (!$has_perm && $is_core)) { + if ($navigation && $tabs) { $navigation->addToolNavigation($module->getPluginId(), $tabs); } } |
