mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
CHORE: Linting and comment-fixing (#2937)
This commit is contained in:
@ -150,6 +150,7 @@ func (dc *DomainConfig) Punycode() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// StoreCorrections accumulates corrections in a thread-safe way.
|
||||
func (dc *DomainConfig) StoreCorrections(providerName string, corrections []*Correction) {
|
||||
dc.pendingCorrectionsMutex.Lock()
|
||||
defer dc.pendingCorrectionsMutex.Unlock()
|
||||
@ -171,6 +172,7 @@ func (dc *DomainConfig) StoreCorrections(providerName string, corrections []*Cor
|
||||
}
|
||||
}
|
||||
|
||||
// GetCorrections returns the accumulated corrections for providerName.
|
||||
func (dc *DomainConfig) GetCorrections(providerName string) []*Correction {
|
||||
dc.pendingCorrectionsMutex.Lock()
|
||||
defer dc.pendingCorrectionsMutex.Unlock()
|
||||
|
@ -497,6 +497,7 @@ func (rc *RecordConfig) Key() RecordKey {
|
||||
return RecordKey{rc.NameFQDN, t}
|
||||
}
|
||||
|
||||
// GetSVCBValue returns the SVCB Key/Values as a list of Key/Values.
|
||||
func (rc *RecordConfig) GetSVCBValue() []dns.SVCBKeyValue {
|
||||
record, err := dns.NewRR(fmt.Sprintf("%s %s %d %s %s", rc.NameFQDN, rc.Type, rc.SvcPriority, rc.target, rc.SvcParams))
|
||||
if err != nil {
|
||||
|
@ -1,5 +1,6 @@
|
||||
package models
|
||||
|
||||
// MakeUnknown turns an RecordConfig into an UNKNOWN type.
|
||||
func MakeUnknown(rc *RecordConfig, rtype string, contents string, origin string) error {
|
||||
rc.Type = "UNKNOWN"
|
||||
rc.UnknownTypeName = rtype
|
||||
|
Reference in New Issue
Block a user