From: Jo-Philipp Wich Date: Fri, 20 Nov 2020 12:28:28 +0000 (+0100) Subject: luci-app-firewall: fix removing networks from zone X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=94cdb6d2f713620eb4773cb914b08586b9f2f89e;p=project%2Fluci.git luci-app-firewall: fix removing networks from zone Fixes: #4608 Signed-off-by: Jo-Philipp Wich (cherry picked from commit 4dbf600de61c0db9052343f0447ee31db79a8346) --- diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js index b24521e1ee..b2f9b81a9b 100644 --- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js +++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js @@ -186,9 +186,11 @@ return view.extend({ } return Promise.all(tasks).then(function(zone_networks) { - if (zone_networks[0]) + if (zone_networks[0]) { + zone_networks[0].clearNetworks(); for (var i = 1; i < zone_networks.length; i++) zone_networks[0].addNetwork(zone_networks[i].getName()); + } }); };