View Issue Details

IDProjectCategoryView StatusLast Update
0016761phplist applicationPlugin APIpublic27-03-13 12:02
Reporterduncanc 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product VersionSVN 
Target Version2.11.8Fixed in Version2.11.8 
Summary0016761: Remove use of eval()
DescriptionUsing SVN trunk

In file pluginlib.php line 59
        eval("\$pluginInstance = new ". $className ."();");

The eval is unnecessary as php allows a variable class name, and can be replaced by:
        $pluginInstance = new $className();
TagsNo tags attached.

Activities

michiel

26-03-13 14:48

manager   ~0051989

I think there was a reason I did it like that, but I can't remember. :-)

duncanc

27-03-13 09:40

developer   ~0051993

Possibly to trap an error when creating the plugin object, but I don't think that eval will do that.

michiel

27-03-13 12:02

manager   ~0051995

yes, seems to work all fine without the eval.