mirror of
https://github.com/pi-hole/web.git
synced 2025-12-24 12:48:29 +00:00
If we left with an empty page (no visible boxes) after switching from Expert to Basic settings, redirect to admin/settings/system instead
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
@@ -696,8 +696,9 @@ function applyExpertSettings() {
|
||||
$(".settings-level-basic").show();
|
||||
$(".settings-level-expert").hide();
|
||||
|
||||
// if we are on admin/settings/all, redirect to admin/settings/system
|
||||
if (window.location.pathname === "/admin/settings/all") {
|
||||
// If we left with an empty page (no visible boxes) after switching from
|
||||
// Expert to Basic settings, redirect to admin/settings/system instead
|
||||
if ($(".box:visible").length === 0) {
|
||||
window.location.href = "/admin/settings/system";
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user