mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Fixed php notice (merged from 2.1.0 branch, r41552)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42911 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
e46e5e73c9
commit
7455457964
@ -388,8 +388,11 @@ class Controller extends ViewableData {
|
|||||||
array_unshift(self::$controller_stack, $this);
|
array_unshift(self::$controller_stack, $this);
|
||||||
// Create a new session object
|
// Create a new session object
|
||||||
if(!$this->session) {
|
if(!$this->session) {
|
||||||
if(self::$controller_stack[1]) $this->session = self::$controller_stack[1]->getSession();
|
if(isset(self::$controller_stack[1])) {
|
||||||
else $this->session = new Session(null);
|
$this->session = self::$controller_stack[1]->getSession();
|
||||||
|
} else {
|
||||||
|
$this->session = new Session(null);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user