luci-mod-network: exclude alias to self from device picker
authorJo-Philipp Wich <jo@mein.io>
Fri, 8 Dec 2023 12:01:13 +0000 (13:01 +0100)
committerJo-Philipp Wich <jo@mein.io>
Fri, 8 Dec 2023 12:01:13 +0000 (13:01 +0100)
Do not present alias to self as valid choice in the interface device picker.

Fixes: #6754
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js

index 3748f04b05fb5b9243741a6148d72a27ac526cc9..8166ac44b15391f7707eed0e4c3f520b34fa972b 100644 (file)
@@ -588,6 +588,7 @@ return view.extend({
                                o.nobridges = false;
                                o.optional = false;
                                o.network = ifc.getName();
+                               o.exclude = '@' + ifc.getName();
 
                                o = s.taboption('general', form.Flag, 'auto', _('Bring up on boot'));
                                o.modalonly = true;