Remove unused variables

This commit is contained in:
David Tolnay 2016-07-01 13:37:48 -07:00
parent 3b732131d2
commit be7162747f
3 changed files with 4 additions and 10 deletions

View File

@ -157,10 +157,8 @@ func resourceAwsCloudWatchEventRuleUpdate(d *schema.ResourceData, meta interface
log.Printf("[DEBUG] Updating CloudWatch Event Rule: %s", input) log.Printf("[DEBUG] Updating CloudWatch Event Rule: %s", input)
// IAM Roles take some time to propagate // IAM Roles take some time to propagate
var out *events.PutRuleOutput
err := resource.Retry(30*time.Second, func() *resource.RetryError { err := resource.Retry(30*time.Second, func() *resource.RetryError {
var err error _, err := conn.PutRule(input)
out, err = conn.PutRule(input)
pattern := regexp.MustCompile("cannot be assumed by principal '[a-z]+\\.amazonaws\\.com'\\.$") pattern := regexp.MustCompile("cannot be assumed by principal '[a-z]+\\.amazonaws\\.com'\\.$")
if err != nil { if err != nil {
if awsErr, ok := err.(awserr.Error); ok { if awsErr, ok := err.(awserr.Error); ok {

View File

@ -299,10 +299,8 @@ func resourceAwsCodeDeployDeploymentGroupUpdate(d *schema.ResourceData, meta int
log.Printf("[DEBUG] Updating CodeDeploy DeploymentGroup %s", d.Id()) log.Printf("[DEBUG] Updating CodeDeploy DeploymentGroup %s", d.Id())
// Retry to handle IAM role eventual consistency. // Retry to handle IAM role eventual consistency.
var resp *codedeploy.UpdateDeploymentGroupOutput err := resource.Retry(5*time.Minute, func() *resource.RetryError {
var err error _, err := conn.UpdateDeploymentGroup(&input)
err = resource.Retry(5*time.Minute, func() *resource.RetryError {
resp, err = conn.UpdateDeploymentGroup(&input)
if err != nil { if err != nil {
retry := false retry := false
codedeployErr, ok := err.(awserr.Error) codedeployErr, ok := err.(awserr.Error)

View File

@ -347,10 +347,8 @@ func resourceAwsOpsworksApplicationUpdate(d *schema.ResourceData, meta interface
log.Printf("[DEBUG] Updating OpsWorks layer: %s", d.Id()) log.Printf("[DEBUG] Updating OpsWorks layer: %s", d.Id())
var resp *opsworks.UpdateAppOutput
err := resource.Retry(2*time.Minute, func() *resource.RetryError { err := resource.Retry(2*time.Minute, func() *resource.RetryError {
var cerr error _, cerr := client.UpdateApp(req)
resp, cerr = client.UpdateApp(req)
if cerr != nil { if cerr != nil {
log.Printf("[INFO] client error") log.Printf("[INFO] client error")
if opserr, ok := cerr.(awserr.Error); ok { if opserr, ok := cerr.(awserr.Error); ok {