Icinga.Loader#onFailure(): on 401, reload the whole page

instead of rendering 401 responses to all containers.

(cherry picked from commit 83459934807ee72b4a5c2c0336b7909871d875ba)
This commit is contained in:
Alexander A. Klimov 2025-04-25 14:27:28 +02:00 committed by Johannes Meyer
parent d3331dd300
commit f8b82d9472

View File

@ -1058,15 +1058,20 @@
errorThrown + ':',
$(req.responseText).text().replace(/\s+/g, ' ').slice(0, 100)
);
this.renderContentToContainer(
req.responseText,
req.$target,
req.action,
req.autorefresh,
undefined,
req.autosubmit,
req.scripted
);
if (req.status === 401) {
window.location.reload();
} else {
this.renderContentToContainer(
req.responseText,
req.$target,
req.action,
req.autorefresh,
undefined,
req.autosubmit,
req.scripted
);
}
} else {
if (errorThrown === 'abort') {
this.icinga.logger.debug(