mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
BUGFIX Removed double check of find_old_page() in ModelAsController
This commit is contained in:
parent
bc4208097f
commit
8b44955c6e
@ -104,7 +104,7 @@ class ModelAsController extends Controller implements NestedController {
|
|||||||
// If a root page has been renamed, redirect to the new location.
|
// If a root page has been renamed, redirect to the new location.
|
||||||
// See ContentController->handleRequest() for similiar logic.
|
// See ContentController->handleRequest() for similiar logic.
|
||||||
$redirect = self::find_old_page($URLSegment);
|
$redirect = self::find_old_page($URLSegment);
|
||||||
if($redirect = self::find_old_page($URLSegment)) {
|
if($redirect) {
|
||||||
$params = $request->getVars();
|
$params = $request->getVars();
|
||||||
if(isset($params['url'])) unset($params['url']);
|
if(isset($params['url'])) unset($params['url']);
|
||||||
$this->response = new SS_HTTPResponse();
|
$this->response = new SS_HTTPResponse();
|
||||||
@ -180,4 +180,4 @@ class ModelAsController extends Controller implements NestedController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user