dnscontrol/providers/cloudflare/auditrecords.go
Tom Limoncelli dad4115a55
CLOUDFLAREAPI: Fix TXT quoting bug (#1543)
* Cleanup

* wip!

* Fix cloudflare quote bug

* wip!

* cleanup

* go generate
2022-06-18 09:58:55 -04:00

25 lines
641 B
Go

package cloudflare
import (
"github.com/StackExchange/dnscontrol/v3/models"
"github.com/StackExchange/dnscontrol/v3/pkg/recordaudit"
)
// AuditRecords returns an error if any records are not
// supportable by this provider.
func AuditRecords(records []*models.RecordConfig) error {
if err := recordaudit.TxtNoMultipleStrings(records); err != nil {
return err
} // Still needed as of 2022-06-18
if err := recordaudit.TxtNoTrailingSpace(records); err != nil {
return err
} // Still needed as of 2022-06-18
if err := recordaudit.TxtNotEmpty(records); err != nil {
return err
} // Still needed as of 2022-06-18
return nil
}