aboutsummaryrefslogtreecommitdiff
path: root/app/controllers/plugin_controller.php
diff options
context:
space:
mode:
authorMoritz Strohm <strohm@data-quest.de>2022-05-04 14:18:41 +0000
committerMoritz Strohm <strohm@data-quest.de>2022-05-04 14:18:41 +0000
commit0d95625c2ab0eabe98e724ab79be0087093cc35b (patch)
treef911e16bfb52f4aceacf9e9ad4c8d31923e26a6e /app/controllers/plugin_controller.php
parente1f835675363c17fbf5d269f6d1d1f84b6727886 (diff)
fix for BIESt #957
Merge request studip/studip!554
Diffstat (limited to 'app/controllers/plugin_controller.php')
-rw-r--r--app/controllers/plugin_controller.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/plugin_controller.php b/app/controllers/plugin_controller.php
index 7710bff..445f22e 100644
--- a/app/controllers/plugin_controller.php
+++ b/app/controllers/plugin_controller.php
@@ -14,8 +14,12 @@ class PluginController extends StudipController
{
parent::__construct($dispatcher);
+ if (!isset($dispatcher->current_plugin)) {
+ throw new Exception('Plugin missing for plugin controller!');
+ }
$this->plugin = $dispatcher->current_plugin;
+
if ($this->plugin && $this->plugin->hasTranslation()) {
// Localization
$this->_ = function ($string) {