diff --git a/pandora_console/include/lib/Entity.php b/pandora_console/include/lib/Entity.php index c22076505d..3304c9e805 100644 --- a/pandora_console/include/lib/Entity.php +++ b/pandora_console/include/lib/Entity.php @@ -178,15 +178,7 @@ abstract class Entity && $this->enterprise !== null && method_exists($this->enterprise, $methodName) === true ) { - $obj = $this->enterprise; - $callback = function (...$parameters) use ($obj, $methodName) { - return $obj->$methodName(...$parameters); - }; - - return call_user_func_array( - $callback, - $params - ); + return $this->enterprise->$methodName(...$params); } if (method_exists($this, $methodName) === false) {