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 5b7d97e commit 977ece0
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 977ece0

Please sign in to comment.