Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions networkapi/interface/resource/InterfaceChannelResource.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def alterar_interface(var, interface, port_channel, int_type, vlan_nativa, user,
raise InterfaceError(
'Interface %s já está em um Channel' % var.interface)

if cont is []:
if cont == []:
cont.append(int(var.equipamento.id))
elif not var.equipamento.id in cont:
cont.append(int(var.equipamento.id))
Expand Down Expand Up @@ -164,7 +164,7 @@ def handle_post(self, request, user, *args, **kwargs):
raise InterfaceError(
'Interface %s já está em um Channel' % sw_router.interface)

if cont is []:
if cont == []:
cont.append(int(sw_router.equipamento.id))
elif not sw_router.equipamento.id in cont:
cont.append(int(sw_router.equipamento.id))
Expand Down