Skip to content

Commit

Permalink
Merge pull request #26 from LuminalHQ/feature/RM-5821/google-redis-pe…
Browse files Browse the repository at this point in the history
…rmission-errors

[RM-5821] Skip auth_string decode for google_redis_instance
  • Loading branch information
mattm-fugue authored Aug 11, 2021
2 parents 24adb41 + fb9b9f9 commit ffb8e61
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions google/resource_redis_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -402,17 +402,17 @@ func resourceRedisInstanceRead(d *schema.ResourceData, meta interface{}) error {
return handleNotFoundError(err, d, fmt.Sprintf("RedisInstance %q", d.Id()))
}

res, err = resourceRedisInstanceDecoder(d, meta, res)
if err != nil {
return err
}

if res == nil {
// Decoding the object has resulted in it being gone. It may be marked deleted
log.Printf("[DEBUG] Removing RedisInstance because it no longer exists.")
d.SetId("")
return nil
}
// res, err = resourceRedisInstanceDecoder(d, meta, res)
// if err != nil {
// return err
// }

// if res == nil {
// // Decoding the object has resulted in it being gone. It may be marked deleted
// log.Printf("[DEBUG] Removing RedisInstance because it no longer exists.")
// d.SetId("")
// return nil
// }

if err := d.Set("project", project); err != nil {
return fmt.Errorf("Error reading Instance: %s", err)
Expand Down

0 comments on commit ffb8e61

Please sign in to comment.