[provider/aws] check that we actually have NodeGroupMembers (#13488)
This commit is contained in:
parent
42fccffdf9
commit
ef4e89c7be
|
@ -267,6 +267,10 @@ func resourceAwsElasticacheReplicationGroupRead(d *schema.ResourceData, meta int
|
||||||
d.Set("replication_group_id", rgp.ReplicationGroupId)
|
d.Set("replication_group_id", rgp.ReplicationGroupId)
|
||||||
|
|
||||||
if rgp.NodeGroups != nil {
|
if rgp.NodeGroups != nil {
|
||||||
|
if len(rgp.NodeGroups[0].NodeGroupMembers) == 0 {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
cacheCluster := *rgp.NodeGroups[0].NodeGroupMembers[0]
|
cacheCluster := *rgp.NodeGroups[0].NodeGroupMembers[0]
|
||||||
|
|
||||||
res, err := conn.DescribeCacheClusters(&elasticache.DescribeCacheClustersInput{
|
res, err := conn.DescribeCacheClusters(&elasticache.DescribeCacheClustersInput{
|
||||||
|
|
Loading…
Reference in New Issue