Version 4.7.6
This commit is contained in:
1 parent
8ba7d43898
commit
7b7404e741
1085 files changed
+30590
-7837
No files matched your search
@@ -34,6 +34,8 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
*/
|
||||
protected function manage()
|
||||
{
|
||||
\IPS\Output::i()->pageCaching = FALSE;
|
||||
|
||||
/* Init login class */
|
||||
$login = new \IPS\Login( \IPS\Http\Url::internal( "app=core&module=system&controller=login", 'front', 'login' ) );
|
||||
|
||||
@@ -112,6 +114,16 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
\IPS\Output::i()->redirect( \IPS\Http\Url::internal('') );
|
||||
}
|
||||
|
||||
/* If there is only one button handler, redirect */
|
||||
if ( !isset( \IPS\Request::i()->_processLogin ) and !$login->usernamePasswordMethods() and \count( $login->buttonMethods() ) == 1 )
|
||||
{
|
||||
$buttonMethod = $login->buttonMethods()[ array_key_first( $login->buttonMethods() ) ];
|
||||
if( method_exists( $buttonMethod, 'authenticateButton' ) )
|
||||
{
|
||||
$buttonMethod->authenticateButton( $login );
|
||||
}
|
||||
}
|
||||
|
||||
/* Display Login Form */
|
||||
\IPS\Output::i()->allowDefaultWidgets = FALSE;
|
||||
\IPS\Output::i()->bodyClasses[] = 'ipsLayout_minimal';
|
||||
|
||||
Reference in new issue
Block a user