Skip to content

Commit

Permalink
fix lint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyYe committed Feb 9, 2024
1 parent 79e9a4f commit bc3e485
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions internal/provider/ovh/ovh_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,21 @@ func (provider *DNSProvider) UpdateIP(domainName string, subdomainName string, i
log.Error("OVH Client error: ", err)
return err
}
var IDS []int
var IDs []int
query := fmt.Sprintf("/domain/zone/%s/record?subDomain=%s", domainName, subdomainName)

err = client.Get(query, &IDS)
err = client.Get(query, &IDs)
if err != nil {
log.Error("Fetch error")
return err
}
if len(IDS) < 1 {
if len(IDs) < 1 {
log.Error("No machting records")
return fmt.Errorf("no macthing records")
}
outrec := Record{}

for _, id := range IDS {
for _, id := range IDs {
record := Record{}
err = client.Get(fmt.Sprintf("/domain/zone/%s/record/%s", domainName, fmt.Sprint(id)), &record)
if err != nil {
Expand Down

0 comments on commit bc3e485

Please sign in to comment.