Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

BUG Dummy Page_Controller initiated during login now is correctly ini…

…tialised via dependency injection
  • Loading branch information...
commit c99991ba7a43aa14236fd0efc65e39aee591dc2d 1 parent fca9831
@tractorcow tractorcow authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 security/Security.php
View
8 security/Security.php
@@ -341,7 +341,7 @@ public function login() {
// Disable ID-based caching of the log-in page by making it a random number
$tmpPage->ID = -1 * rand(1,10000000);
- $controller = new Page_Controller($tmpPage);
+ $controller = Page_Controller::create($tmpPage);
$controller->setDataModel($this->model);
$controller->init();
//Controller::$currentController = $controller;
@@ -436,7 +436,7 @@ public function lostpassword() {
$tmpPage->Title = _t('Security.LOSTPASSWORDHEADER', 'Lost Password');
$tmpPage->URLSegment = 'Security';
$tmpPage->ID = -1; // Set the page ID to -1 so we dont get the top level pages as its children
- $controller = new Page_Controller($tmpPage);
+ $controller = Page_Controller::create($tmpPage);
$controller->init();
} else {
$controller = $this;
@@ -495,7 +495,7 @@ public function passwordsent($request) {
$tmpPage->Title = _t('Security.LOSTPASSWORDHEADER');
$tmpPage->URLSegment = 'Security';
$tmpPage->ID = -1; // Set the page ID to -1 so we dont get the top level pages as its children
- $controller = new Page_Controller($tmpPage);
+ $controller = Page_Controller::create($tmpPage);
$controller->init();
} else {
$controller = $this;
@@ -553,7 +553,7 @@ public function changepassword() {
$tmpPage->Title = _t('Security.CHANGEPASSWORDHEADER', 'Change your password');
$tmpPage->URLSegment = 'Security';
$tmpPage->ID = -1; // Set the page ID to -1 so we dont get the top level pages as its children
- $controller = new Page_Controller($tmpPage);
+ $controller = Page_Controller::create($tmpPage);
$controller->init();
} else {
$controller = $this;
Please sign in to comment.
Something went wrong with that request. Please try again.