From d3c6caf8a8db5cc643f0f5ed7fab2c78dff97c28 Mon Sep 17 00:00:00 2001 From: hSaria <34197532+hSaria@users.noreply.github.com> Date: Thu, 2 Jan 2020 17:52:22 +0000 Subject: [PATCH] Limit tagged validation to tagged interfaces Co-Authored-By: Jeremy Stretch --- netbox/dcim/forms.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netbox/dcim/forms.py b/netbox/dcim/forms.py index 3c515152e..902541353 100644 --- a/netbox/dcim/forms.py +++ b/netbox/dcim/forms.py @@ -75,7 +75,7 @@ class InterfaceCommonForm: self.cleaned_data['tagged_vlans'] = [] # Validate tagged VLANs; must be a global VLAN or in the same site - else: + elif self.cleaned_data['mode'] == IFACE_MODE_TAGGED: valid_sites = [None, self.cleaned_data['device'].site] invalid_vlans = [str(v) for v in tagged_vlans if v.site not in valid_sites]