From 8b44955c6e06558e58aad2d223ffead7158a38e2 Mon Sep 17 00:00:00 2001 From: Sean Harvey Date: Wed, 11 Apr 2012 14:51:33 +1200 Subject: [PATCH] BUGFIX Removed double check of find_old_page() in ModelAsController --- code/controllers/ModelAsController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/controllers/ModelAsController.php b/code/controllers/ModelAsController.php index 8789f2da..a6ba308c 100644 --- a/code/controllers/ModelAsController.php +++ b/code/controllers/ModelAsController.php @@ -104,7 +104,7 @@ class ModelAsController extends Controller implements NestedController { // If a root page has been renamed, redirect to the new location. // See ContentController->handleRequest() for similiar logic. $redirect = self::find_old_page($URLSegment); - if($redirect = self::find_old_page($URLSegment)) { + if($redirect) { $params = $request->getVars(); if(isset($params['url'])) unset($params['url']); $this->response = new SS_HTTPResponse(); @@ -180,4 +180,4 @@ class ModelAsController extends Controller implements NestedController { } } -} \ No newline at end of file +}