Skip to content

Commit b799477

Browse files
committed
fixing get_device_vlans
1 parent f86266e commit b799477

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

netdot/Client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -624,8 +624,8 @@ def get_device_vlans(self, device):
624624
iface_vlans = self.get_object_by_filter('interfacevlan', 'interface', iface)
625625
for iv in iface_vlans['InterfaceVlan'].keys():
626626
print iv
627-
if iv['vlan'] not in dev_vlans:
628-
dev_vlans.append(iv['vlan'])
627+
if iface_vlans['InterfaceVlan'][iv]['vlan'] not in dev_vlans:
628+
dev_vlans.append(iface_vlans['InterfaceVlan'][iv]['vlan'])
629629
except requests.exceptions.HTTPError as e:
630630
# This is caused by SVI interfaces. They don't have a Vlan
631631
# because they are Vlans...

0 commit comments

Comments
 (0)