From bf35a7bc488fc21749c6faec0b11a0ff5b94885a Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Mon, 1 Feb 2010 03:47:35 +0000 Subject: [PATCH] BUGFIX Checking that URL controller in HTTPRequest->match() is a subclass of Controller, not RequestHandler (which would include nested controllers like Form or FormField subclasses that shouldn't be accessible on their own toplevel URL namespace) git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97881 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- core/control/HTTPRequest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/control/HTTPRequest.php b/core/control/HTTPRequest.php index 18987c0c9..d77e4f362 100755 --- a/core/control/HTTPRequest.php +++ b/core/control/HTTPRequest.php @@ -342,7 +342,7 @@ class SS_HTTPRequest implements ArrayAccess { if($varRequired && !isset($this->dirParts[$i])) return false; $arguments[$varName] = isset($this->dirParts[$i]) ? $this->dirParts[$i] : null; - if($part == '$Controller' && (!ClassInfo::exists($arguments['Controller']) || !ClassInfo::is_subclass_of($arguments['Controller'], 'RequestHandler'))) { + if($part == '$Controller' && (!ClassInfo::exists($arguments['Controller']) || !ClassInfo::is_subclass_of($arguments['Controller'], 'Controller'))) { return false; }