mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 16:54:04 +02:00
Don't fire application-state requests if not authenticated
fixes #10749
This commit is contained in:
parent
4f562280ba
commit
f5dac49330
@ -20,7 +20,7 @@ class ApplicationStateController extends Controller
|
|||||||
$last = 0;
|
$last = 0;
|
||||||
}
|
}
|
||||||
$now = time();
|
$now = time();
|
||||||
if ($last + 60 < $now) {
|
if ($last + 600 < $now) {
|
||||||
Session::getSession()->write();
|
Session::getSession()->write();
|
||||||
$params = session_get_cookie_params();
|
$params = session_get_cookie_params();
|
||||||
setcookie(
|
setcookie(
|
||||||
|
@ -16,8 +16,9 @@
|
|||||||
ApplicationState.prototype = new Icinga.EventListener();
|
ApplicationState.prototype = new Icinga.EventListener();
|
||||||
|
|
||||||
ApplicationState.prototype.onRendered = function(e) {
|
ApplicationState.prototype.onRendered = function(e) {
|
||||||
var _this = e.data.self;
|
if (! $('#application-state').length && ! $('#login').length && ! $('#guest-error').length) {
|
||||||
if (! $('#application-state').length) {
|
var _this = e.data.self;
|
||||||
|
|
||||||
$('#layout').append(
|
$('#layout').append(
|
||||||
'<div id="application-state" class="container" style="display: none" data-icinga-url="'
|
'<div id="application-state" class="container" style="display: none" data-icinga-url="'
|
||||||
+ _this.icinga.loader.baseUrl
|
+ _this.icinga.loader.baseUrl
|
||||||
|
Loading…
x
Reference in New Issue
Block a user