diff --git a/builtin/providers/heroku/resource_heroku_addon.go b/builtin/providers/heroku/resource_heroku_addon.go index c770456a8..cd6ba3f9c 100644 --- a/builtin/providers/heroku/resource_heroku_addon.go +++ b/builtin/providers/heroku/resource_heroku_addon.go @@ -25,6 +25,10 @@ func resourceHerokuAddon() *schema.Resource { Update: resourceHerokuAddonUpdate, Delete: resourceHerokuAddonDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Schema: map[string]*schema.Schema{ "app": { Type: schema.TypeString, @@ -111,8 +115,7 @@ func resourceHerokuAddonCreate(d *schema.ResourceData, meta interface{}) error { func resourceHerokuAddonRead(d *schema.ResourceData, meta interface{}) error { client := meta.(*heroku.Service) - addon, err := resourceHerokuAddonRetrieveByApp( - d.Get("app").(string), d.Id(), client) + addon, err := resourceHerokuAddonRetrieve(d.Id(), client) if err != nil { return err }