From e6815f2156c51f880305f74e12cd127a0950e4ac Mon Sep 17 00:00:00 2001 From: Sean Harvey Date: Wed, 8 Oct 2008 01:49:49 +0000 Subject: [PATCH] BUGFIX Side reports weren't working on initial opening of the side tab git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@63804 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- code/CMSMain.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/CMSMain.php b/code/CMSMain.php index b3cd5492..95754cb8 100644 --- a/code/CMSMain.php +++ b/code/CMSMain.php @@ -722,8 +722,8 @@ HTML; */ function sidereport() { $reportClass = $this->urlParams['ID']; - $report = new $reportClass(); - return $report->getHTML(); + $report = ClassInfo::exists($reportClass) ? new $reportClass() : false; + return $report ? $report->getHTML() : false; } /** * Get the versions of the current page