From 22d85e506c5db1b3577ff12764e15e602ebc5746 Mon Sep 17 00:00:00 2001 From: Chris Kuchin Date: Mon, 20 Nov 2023 10:01:05 -0700 Subject: [PATCH] Fix Missing Arg --- internal/bowtie/client/dns.go | 6 +++--- internal/bowtie/resources/dns.go | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/internal/bowtie/client/dns.go b/internal/bowtie/client/dns.go index fac045a..3a9cfdc 100644 --- a/internal/bowtie/client/dns.go +++ b/internal/bowtie/client/dns.go @@ -9,12 +9,12 @@ import ( "github.com/google/uuid" ) -func (c *Client) CreateDNS(name string, serverAddrs []Server, includeOnlySites []string, isCounted, isLog, isDropA, isDropAll, isSearchDomain bool, exlude []DNSExclude) (string, error) { +func (c *Client) CreateDNS(name string, serverAddrs []Server, includeOnlySites []string, isDNS64, isCounted, isLog, isDropA, isDropAll, isSearchDomain bool, exlude []DNSExclude) (string, error) { id := uuid.NewString() - return id, c.UpsertDNS(id, name, serverAddrs, includeOnlySites, isCounted, isLog, isDropA, isDropAll, isSearchDomain, exlude) + return id, c.UpsertDNS(id, name, serverAddrs, includeOnlySites, isDNS64, isCounted, isLog, isDropA, isDropAll, isSearchDomain, exlude) } -func (c *Client) UpsertDNS(id, name string, serverAddrs []Server, includeOnlySites []string, isCounted, isLog, isDropA, isDropAll, isSearchDomain bool, exlude []DNSExclude) error { +func (c *Client) UpsertDNS(id, name string, serverAddrs []Server, includeOnlySites []string, isDNS64, isCounted, isLog, isDropA, isDropAll, isSearchDomain bool, exlude []DNSExclude) error { var servers map[string]Server = map[string]Server{} for _, addr := range serverAddrs { servers[addr.ID] = addr diff --git a/internal/bowtie/resources/dns.go b/internal/bowtie/resources/dns.go index b47d308..0ce36a5 100644 --- a/internal/bowtie/resources/dns.go +++ b/internal/bowtie/resources/dns.go @@ -221,7 +221,7 @@ func (d *dnsResource) Create(ctx context.Context, req resource.CreateRequest, re }) } - id, err := d.client.CreateDNS(plan.Name.ValueString(), servers, includeSites, plan.IsCounted.ValueBool(), plan.IsLog.ValueBool(), plan.IsDropA.ValueBool(), plan.IsDropAll.ValueBool(), plan.IsSearchDomain.ValueBool(), excludes) + id, err := d.client.CreateDNS(plan.Name.ValueString(), servers, includeSites, plan.IsDNS64.ValueBool(), plan.IsCounted.ValueBool(), plan.IsLog.ValueBool(), plan.IsDropA.ValueBool(), plan.IsDropAll.ValueBool(), plan.IsSearchDomain.ValueBool(), excludes) if err != nil { resp.Diagnostics.AddError( "Failed talking to bowtie server", @@ -340,7 +340,7 @@ func (d *dnsResource) Update(ctx context.Context, req resource.UpdateRequest, re }) } - err := d.client.UpsertDNS(plan.ID.ValueString(), plan.Name.ValueString(), servers, includes, plan.IsCounted.ValueBool(), plan.IsLog.ValueBool(), plan.IsDropA.ValueBool(), plan.IsDropAll.ValueBool(), plan.IsSearchDomain.ValueBool(), excludes) + err := d.client.UpsertDNS(plan.ID.ValueString(), plan.Name.ValueString(), servers, includes, plan.IsDNS64.ValueBool(), plan.IsCounted.ValueBool(), plan.IsLog.ValueBool(), plan.IsDropA.ValueBool(), plan.IsDropAll.ValueBool(), plan.IsSearchDomain.ValueBool(), excludes) if err != nil { resp.Diagnostics.AddError( "Failed updating the dns settings",