Fix issue with unamed devices
This commit is contained in:
parent
ba91313e55
commit
00e8bc7ca3
1 changed files with 6 additions and 5 deletions
|
@ -66,6 +66,7 @@ def ptr(nb, args):
|
||||||
if address.assigned_object.device.id in device_cluster:
|
if address.assigned_object.device.id in device_cluster:
|
||||||
address.assigned_object.device.name = device_cluster[address.assigned_object.device.id]
|
address.assigned_object.device.name = device_cluster[address.assigned_object.device.id]
|
||||||
|
|
||||||
|
if address.assigned_object.device.name is not None:
|
||||||
if address.assigned_object.device.id in device_primary and address.id == device_primary[address.assigned_object.device.id]:
|
if address.assigned_object.device.id in device_primary and address.id == device_primary[address.assigned_object.device.id]:
|
||||||
records[ptr] = [{"type":"PTR","rr":address.assigned_object.device.name}]
|
records[ptr] = [{"type":"PTR","rr":address.assigned_object.device.name}]
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue