Skip to content

Commit

Permalink
fix(network): retrieve switch interface using id instead of name
Browse files Browse the repository at this point in the history
  • Loading branch information
clbu committed Oct 16, 2024
1 parent 1429fed commit e44fd2f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion netbox_agent/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ def connect_interface_to_switch(self, switch_ip, switch_interface, nb_server_int

switch_interface = self.lldp.get_switch_port(nb_server_interface.name)
nb_switch_interface = nb.dcim.interfaces.get(
device=nb_switch,
device_id=nb_switch.id,
name=switch_interface,
)
if nb_switch_interface is None:
Expand Down

0 comments on commit e44fd2f

Please sign in to comment.