Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.

Avoid duplicate save() operation for new records #233

Merged
merged 1 commit into from
Oct 17, 2022
Merged
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
3 changes: 2 additions & 1 deletion netbox_dns/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -659,7 +659,8 @@ def update_ptr_record(self):
)

self.ptr_record = ptr_record
super().save()
if self.pk:
super().save()

def clean_fields(self, *args, **kwargs):
self.type = self.type.upper()
Expand Down