forked from D3Public/oxtotp
prevent empty page at logout, clear error messages after displaying it
This commit is contained in:
parent
cea9e246ba
commit
9e15477737
@ -23,17 +23,17 @@ class d3_account_totp extends AccountController
|
||||
|
||||
public function render()
|
||||
{
|
||||
$sRet = parent::render();
|
||||
|
||||
// is logged in ?
|
||||
$oUser = $this->getUser();
|
||||
if (!$oUser) {
|
||||
dumpvar(__LINE__);
|
||||
dumpvar($this->_sThisLoginTemplate);
|
||||
return $this->_sThisTemplate = $this->_sThisLoginTemplate;
|
||||
}
|
||||
|
||||
$this->addTplParam('user', $this->getUser());
|
||||
|
||||
return parent::render();
|
||||
return $sRet;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -81,7 +81,7 @@ class d3_totp_UserComponent extends d3_totp_UserComponent_parent
|
||||
return false;
|
||||
}
|
||||
} catch (d3totp_wrongOtpException $oEx) {
|
||||
Registry::getUtilsView()->addErrorToDisplay($oEx);
|
||||
Registry::getUtilsView()->addErrorToDisplay($oEx, false, false, "", 'd3totplogin');
|
||||
}
|
||||
|
||||
return 'd3totplogin';
|
||||
|
Loading…
Reference in New Issue
Block a user