Refactor: Disallow TS on Host/Container Networks

This commit is contained in:
Squidly271
2025-02-24 06:30:58 -05:00
committed by GitHub
parent 010ad2053b
commit 8f1bf83905

View File

@@ -1552,7 +1552,7 @@ function showSubnet(bridge) {
}
// make sure to re-trigger Tailscale check when network is changed
if (bridge.match(/^(host|container)$/i) !== null) {
$('#contTailscale').click().switchButton({checked: false}).prop('checked',false);
$('#contTailscale').siblings('.switch-button-background').click();
$(".TSNetworkAllowed").hide();
$(".TSNetworkNotAllowed").show();
} else {
@@ -1713,7 +1713,7 @@ function showTSAdvanced(checked) {
function showTailscale(source) {
var bridge = $('select[name="contNetwork"]').val();
if (bridge.match(/^(host|container)$/i) !== null) {
$('#contTailscale').click().switchButton({checked: false}).prop('checked',false);
$('#contTailscale').prop('checked',false);
$(".TSNetworkAllowed").hide();
$(".TSNetworkNotAllowed").show();
}