mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR formatting in Security.php
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@68457 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
042a4f0fac
commit
d10d8a5ba2
@ -174,20 +174,12 @@ class Security extends Controller {
|
||||
|
||||
// Work out the right message to show
|
||||
if(Member::currentUserID()) {
|
||||
// user_error( 'PermFailure with member', E_USER_ERROR );
|
||||
|
||||
$message = isset($messageSet['alreadyLoggedIn'])
|
||||
? $messageSet['alreadyLoggedIn']
|
||||
: $messageSet['default'];
|
||||
|
||||
if($member = Member::currentUser())
|
||||
$member->logout();
|
||||
|
||||
$message = isset($messageSet['alreadyLoggedIn']) ? $messageSet['alreadyLoggedIn'] : $messageSet['default'];
|
||||
if($member = Member::currentUser()) {
|
||||
$member->logOut();
|
||||
}
|
||||
} else if(substr(Director::history(),0,15) == 'Security/logout') {
|
||||
$message = $messageSet['logInAgain']
|
||||
? $messageSet['logInAgain']
|
||||
: $messageSet['default'];
|
||||
|
||||
$message = $messageSet['logInAgain'] ? $messageSet['logInAgain'] : $messageSet['default'];
|
||||
} else {
|
||||
$message = $messageSet['default'];
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user