Version 4.6.0
This commit is contained in:
1 parent
f79dcf067a
commit
517a5e1f70
2036 files changed
+110041
-26162
No files matched your search
@@ -37,6 +37,11 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
/* Do we have an unfinished upgrade? */
|
||||
if ( !\IPS\IN_DEV and ( \IPS\RECOVERY_MODE !== TRUE OR !isset( \IPS\Request::i()->noWarning ) ) and \IPS\Settings::i()->setup_in_progress )
|
||||
{
|
||||
/* Don't allow the upgrade in progress page to be cached, it will only be displayed for a very short period of time */
|
||||
foreach( \IPS\Output::getNoCacheHeaders() as $headerKey => $headerValue )
|
||||
{
|
||||
header( "{$headerKey}: {$headerValue}" );
|
||||
}
|
||||
include( \IPS\ROOT_PATH . '/' . \IPS\CP_DIRECTORY . '/upgrade/upgradeStarted.php' );
|
||||
session_abort();
|
||||
exit;
|
||||
@@ -285,5 +290,14 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
|
||||
\IPS\Db::i()->insert( 'core_admin_login_logs', $save );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return current CSRF token
|
||||
*
|
||||
* @return string|null
|
||||
*/
|
||||
public function getCsrfKey(): ?string
|
||||
{
|
||||
\IPS\Output::i()->json( [ 'key' => \IPS\Session::i()->csrfKey ] );
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user