From 5ccb02db9e3cd08382520144c431050fb24a8cf5 Mon Sep 17 00:00:00 2001 From: "Bruno O. Notario" Date: Sun, 11 Jul 2021 05:15:45 -0300 Subject: [PATCH] Use class_alias instead eval for legacy class --- system/engine/autoload.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/system/engine/autoload.php b/system/engine/autoload.php index 4a8f228..996be67 100644 --- a/system/engine/autoload.php +++ b/system/engine/autoload.php @@ -30,7 +30,8 @@ spl_autoload_register(function ($class) { if(in_array($class, $legacy)){ - eval("class ".$class." extends \\Phacil\\Framework\\".$class." {}"); + class_alias("\\Phacil\\Framework\\".$class, $class); + //eval("class ".$class." extends \\Phacil\\Framework\\".$class." {}"); return; }