mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
REFACTOR: Opinion: TXT records are one long string (#2631)
Co-authored-by: Costas Drogos <costas.drogos@gmail.com> Co-authored-by: imlonghao <git@imlonghao.com> Co-authored-by: Jeffrey Cafferata <jeffrey@jcid.nl> Co-authored-by: Vincent Hagen <blackshadev@users.noreply.github.com>
This commit is contained in:
@ -569,7 +569,7 @@ func checkCNAMEs(dc *models.DomainConfig) (errs []error) {
|
||||
func checkDuplicates(records []*models.RecordConfig) (errs []error) {
|
||||
seen := map[string]*models.RecordConfig{}
|
||||
for _, r := range records {
|
||||
diffable := fmt.Sprintf("%s %s %s", r.GetLabelFQDN(), r.Type, r.ToDiffable())
|
||||
diffable := fmt.Sprintf("%s %s %s", r.GetLabelFQDN(), r.Type, r.ToComparableNoTTL())
|
||||
if seen[diffable] != nil {
|
||||
errs = append(errs, fmt.Errorf("exact duplicate record found: %s", diffable))
|
||||
}
|
||||
|
Reference in New Issue
Block a user