Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
jhanrahan-sigsci committed Mar 9, 2021
1 parent 24b9d7f commit e68c792
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions provider/resource_corp_signal_tag.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/signalsciences/go-sigsci"
"reflect"
)

//TODO maybe rename to corp tag
Expand Down Expand Up @@ -71,16 +70,11 @@ func resourceCorpSignalTagUpdate(d *schema.ResourceData, m interface{}) error {
pm := m.(providerMetadata)
sc := pm.Client
corp := pm.Corp
before, err := sc.GetCorpSignalTagByID(corp, d.Id())
if err != nil {
d.SetId("")
return fmt.Errorf("%s. Could not find signaltag to update with ID %s in corp %s", err.Error(), d.Id(), corp)
}
updateSignalTagBody := sigsci.UpdateSignalTagBody{
Description: d.Get("description").(string),
}

_, err = sc.UpdateCorpSignalTagByID(corp, d.Id(), updateSignalTagBody)
_, err := sc.UpdateCorpSignalTagByID(corp, d.Id(), updateSignalTagBody)
if err != nil {
return fmt.Errorf("%s. Could not update signaltag with ID %s in corp %s", err.Error(), d.Id(), corp)
}
Expand Down

0 comments on commit e68c792

Please sign in to comment.