diff options
author | Jo-Philipp Wich <jo@mein.io> | 2024-04-20 23:13:12 +0200 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2024-04-20 23:14:25 +0200 |
commit | ea04003657cc06ee69639aaede24b4c74071946c (patch) | |
tree | e1210ae7d3d7022b64d5860cc39f0502e45a2a6c /modules | |
parent | 0c92d30d6f42ae321fe4408a46b5739cd6080a28 (diff) |
luci-mod-network: fix potential null dereference on deleting VLANs
Fixes: #7074
Fixes: 61cef9baad ("luci-mod-network: don't trigger uci save on removing bridge vlans")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'modules')
-rw-r--r-- | modules/luci-mod-network/htdocs/luci-static/resources/tools/network.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/tools/network.js b/modules/luci-mod-network/htdocs/luci-static/resources/tools/network.js index 40ab9637b4..09447cdf2b 100644 --- a/modules/luci-mod-network/htdocs/luci-static/resources/tools/network.js +++ b/modules/luci-mod-network/htdocs/luci-static/resources/tools/network.js @@ -921,7 +921,7 @@ return baseclass.extend({ ss.handleRemove = function(section_id) { this.map.data.remove('network', section_id); - s.map.addedVLANs = s.map.addedVLANs.filter(function(sid) { + s.map.addedVLANs = (s.map.addedVLANs || []).filter(function(sid) { return sid != section_id; }); |