Replaced raise with return False statement and added return True at the end of the function.

This commit is contained in:
TheNetworkGuy
2026-02-23 14:04:56 +01:00
parent 0b92586057
commit b7b399444c
+2 -1
View File
@@ -184,7 +184,7 @@ class Sync:
if not self.netbox or not self.zabbix:
e = "Not connected to NetBox or Zabbix. Please run the connect function first."
logger.error(e)
raise SyncError(e)
return False
device_cfs = []
vm_cfs = []
# Create API call to get all custom fields which are on the device objects
@@ -422,3 +422,4 @@ class Sync:
except SyncError:
pass
self.zabbix.logout()
return True