mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-29 11:56:25 -06:00
Prevent cleanup of tagged_vlans when no tagged_vlans set on interface
This commit is contained in:
parent
5c9a145255
commit
282836c9a0
@ -913,7 +913,7 @@ class Interface(ModularComponentModel, BaseInterface, CabledObjectModel, PathEnd
|
||||
self.rf_channel_width = get_channel_attr(self.rf_channel, 'width')
|
||||
|
||||
# Clear any tagged vlans set when mode is tagged-all
|
||||
if self.mode == InterfaceModeChoices.MODE_TAGGED_ALL and self.tagged_vlans:
|
||||
if self.mode == InterfaceModeChoices.MODE_TAGGED_ALL and self.tagged_vlans.count():
|
||||
self.tagged_vlans.set([])
|
||||
|
||||
super().save(*args, **kwargs)
|
||||
|
Loading…
Reference in New Issue
Block a user