diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index ee18404ab..c262a1592 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -6,6 +6,7 @@ - fixed #11773: SQL injection vulnerability in Edit Thing form processing code. - fixed #11906: Carousel slide height problems - fixed #11900: Request Approval for Version Tag Workflow activity can't select --Continue with this workflow + - fixed #11898: String eval used in Image::Graph 7.10.2 - fixed #11884: Editing Templates impossible / Code editor not loaded diff --git a/lib/WebGUI/Image/Graph.pm b/lib/WebGUI/Image/Graph.pm index 0bd611fb5..3b6931051 100644 --- a/lib/WebGUI/Image/Graph.pm +++ b/lib/WebGUI/Image/Graph.pm @@ -6,6 +6,7 @@ use WebGUI::Image::Palette; use WebGUI::Image::Font; use List::Util; use WebGUI::Utility; +use WebGUI::Pluggable; our @ISA = qw(WebGUI::Image); @@ -545,11 +546,9 @@ sub load { my $session = shift; my $namespace = shift; - my $cmd = "use $namespace"; - eval($cmd); - - $cmd = $namespace.'->new($session)'; - my $plugin = eval($cmd); + my $plugin = eval { + WebGUI::Pluggable::instanciate($namespace, 'new', [$session, ]); + }; return $plugin; }