mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
CHORE: Linting (#1704)
* Remove deprecated io/ioutil * fixup! * staticcheck and linting * revert models/provider.go * Fix imports to new style * linting
This commit is contained in:
@@ -7,14 +7,13 @@ import (
|
||||
"net"
|
||||
"strings"
|
||||
|
||||
"github.com/cloudflare/cloudflare-go"
|
||||
"github.com/miekg/dns/dnsutil"
|
||||
|
||||
"github.com/StackExchange/dnscontrol/v3/models"
|
||||
"github.com/StackExchange/dnscontrol/v3/pkg/diff"
|
||||
"github.com/StackExchange/dnscontrol/v3/pkg/printer"
|
||||
"github.com/StackExchange/dnscontrol/v3/pkg/transform"
|
||||
"github.com/StackExchange/dnscontrol/v3/providers"
|
||||
"github.com/cloudflare/cloudflare-go"
|
||||
"github.com/miekg/dns/dnsutil"
|
||||
)
|
||||
|
||||
/*
|
||||
|
@@ -150,13 +150,13 @@ func (c *cloudflareProvider) createRec(rec *models.RecordConfig, domainID string
|
||||
} else if rec.Type == "DS" {
|
||||
cf.Data = cfDSData(rec)
|
||||
}
|
||||
if resp, err := c.cfClient.CreateDNSRecord(context.Background(), domainID, cf); err != nil {
|
||||
resp, err := c.cfClient.CreateDNSRecord(context.Background(), domainID, cf)
|
||||
if err != nil {
|
||||
return err
|
||||
} else {
|
||||
// Updating id (from the outer scope) by side-effect, required for updating proxy mode
|
||||
id = resp.Result.ID
|
||||
return nil
|
||||
}
|
||||
// Updating id (from the outer scope) by side-effect, required for updating proxy mode
|
||||
id = resp.Result.ID
|
||||
return nil
|
||||
},
|
||||
}}
|
||||
if rec.Metadata[metaProxy] != "off" {
|
||||
|
Reference in New Issue
Block a user