summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2019-05-06 08:22:39 +0200
committerJo-Philipp Wich <jo@mein.io>2019-05-06 08:22:39 +0200
commit0ac85a440a0295acf5c3fd9abe84d46514647909 (patch)
treea8e29c0f8bb0f2cf2e72eb9bc3748cca103f74b5
parenta5a731a660452ec3846976506585ab0d9a6e6d1f (diff)
luci-base: remove interface from zone upon deletion
Fixes: #2690 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
-rw-r--r--modules/luci-base/luasrc/model/network.lua6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/luci-base/luasrc/model/network.lua b/modules/luci-base/luasrc/model/network.lua
index 67a2de4ed..a36a23f32 100644
--- a/modules/luci-base/luasrc/model/network.lua
+++ b/modules/luci-base/luasrc/model/network.lua
@@ -622,6 +622,12 @@ function del_network(self, n)
_uci:delete("wireless", s['.name'], "network")
end
end)
+
+ local ok, fw = pcall(require, "luci.model.firewall")
+ if ok then
+ fw.init()
+ fw:del_network(n)
+ end
end
return r
end