Skip to content

Commit

Permalink
Fixed "LabelTooLong" exception in record forms
Browse files Browse the repository at this point in the history
  • Loading branch information
peteeckel committed Oct 20, 2023
1 parent f460a47 commit 7afa6ed
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions netbox_dns/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,8 @@ def __str__(self):
)
except dns_name.IDNAException:
name = self.name
except dns_name.LabelTooLong as exc:
name = f"{self.name[:59]}..."

return f"{name} [{self.type}]"

Expand Down

0 comments on commit 7afa6ed

Please sign in to comment.