1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Closes #14119: Remove redundant check for to_objectchange()

This commit is contained in:
Jeremy Stretch
2023-12-21 16:26:20 -05:00
parent f0b9008529
commit e5c565cbf4

View File

@ -62,8 +62,7 @@ def handle_changed_object(sender, instance, **kwargs):
else:
return
# Record an ObjectChange if applicable
if hasattr(instance, 'to_objectchange'):
# Record an ObjectChange
if m2m_changed:
ObjectChange.objects.filter(
changed_object_type=ContentType.objects.get_for_model(instance),