From 5974e61b65c86eba9c3d5430bebd3762583b3962 Mon Sep 17 00:00:00 2001 From: Jan-Hendrik Willms <tleilax+studip@gmail.com> Date: Tue, 22 Oct 2024 16:12:11 +0000 Subject: [PATCH] restore potentially overwritten variable, fixes #4739 Closes #4739 Merge request studip/studip!3536 --- lib/plugins/engine/PluginManager.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/plugins/engine/PluginManager.php b/lib/plugins/engine/PluginManager.php index 05e2b143607..919e175f65e 100644 --- a/lib/plugins/engine/PluginManager.php +++ b/lib/plugins/engine/PluginManager.php @@ -363,6 +363,10 @@ class PluginManager require_once $pluginfile; + // Restore variable $class that might have been overwritten by the + // previous require + $class = func_get_arg(0); + return new ReflectionClass($class); } -- GitLab