From 765cd1f4942fa83530e8636a42dc0212d7323a13 Mon Sep 17 00:00:00 2001 From: Jakub Janczak Date: Mon, 15 Dec 2014 15:10:59 +0100 Subject: [PATCH] Heroku SSL support: fixes after code review of @svanharmelen --- builtin/providers/heroku/resource_heroku_cert.go | 6 ++---- builtin/providers/heroku/resource_heroku_cert_test.go | 5 ----- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/builtin/providers/heroku/resource_heroku_cert.go b/builtin/providers/heroku/resource_heroku_cert.go index 9032df492..90a49c2b4 100644 --- a/builtin/providers/heroku/resource_heroku_cert.go +++ b/builtin/providers/heroku/resource_heroku_cert.go @@ -70,7 +70,7 @@ func resourceHerokuCertCreate(d *schema.ResourceData, meta interface{}) error { func resourceHerokuCertRead(d *schema.ResourceData, meta interface{}) error { client := meta.(*heroku.Service) - cert, err := resource_heroku_ssl_cert_retrieve( + cert, err := resourceHerokuSSLCertRetrieve( d.Get("app").(string), d.Id(), client) if err != nil { return err @@ -79,8 +79,6 @@ func resourceHerokuCertRead(d *schema.ResourceData, meta interface{}) error { d.Set("certificate_chain", cert.CertificateChain) d.Set("name", cert.Name) d.Set("cname", cert.CName) - d.Set("created_at", cert.CreatedAt) - d.Set("updated_at", cert.UpdatedAt) return nil } @@ -125,7 +123,7 @@ func resourceHerokuCertDelete(d *schema.ResourceData, meta interface{}) error { return nil } -func resource_heroku_ssl_cert_retrieve(app string, id string, client *heroku.Service) (*heroku.SSLEndpoint, error) { +func resourceHerokuSSLCertRetrieve(app string, id string, client *heroku.Service) (*heroku.SSLEndpoint, error) { addon, err := client.SSLEndpointInfo(app, id) if err != nil { diff --git a/builtin/providers/heroku/resource_heroku_cert_test.go b/builtin/providers/heroku/resource_heroku_cert_test.go index 0422e0e7d..89dcc55ce 100644 --- a/builtin/providers/heroku/resource_heroku_cert_test.go +++ b/builtin/providers/heroku/resource_heroku_cert_test.go @@ -21,11 +21,6 @@ func TestAccHerokuCert_Basic(t *testing.T) { resource "heroku_app" "foobar" { name = "terraform-test-cert-app" region = "eu" - organization = { - name = "plan3-labs" - locked = false - private = false - } } resource "heroku_addon" "ssl" {