@@ -807,7 +807,7 @@ func expandContainerAwsClusterAuthorization(o interface{}) *containeraws.Cluster
807
807
return containeraws .EmptyClusterAuthorization
808
808
}
809
809
objArr := o .([]interface {})
810
- if len (objArr ) == 0 {
810
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
811
811
return containeraws .EmptyClusterAuthorization
812
812
}
813
813
obj := objArr [0 ].(map [string ]interface {})
@@ -833,7 +833,7 @@ func expandContainerAwsClusterAuthorizationAdminUsersArray(o interface{}) []cont
833
833
}
834
834
835
835
objs := o .([]interface {})
836
- if len (objs ) == 0 {
836
+ if len (objs ) == 0 || objs [ 0 ] == nil {
837
837
return make ([]containeraws.ClusterAuthorizationAdminUsers , 0 )
838
838
}
839
839
@@ -888,7 +888,7 @@ func expandContainerAwsClusterControlPlane(o interface{}) *containeraws.ClusterC
888
888
return containeraws .EmptyClusterControlPlane
889
889
}
890
890
objArr := o .([]interface {})
891
- if len (objArr ) == 0 {
891
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
892
892
return containeraws .EmptyClusterControlPlane
893
893
}
894
894
obj := objArr [0 ].(map [string ]interface {})
@@ -938,7 +938,7 @@ func expandContainerAwsClusterControlPlaneAwsServicesAuthentication(o interface{
938
938
return containeraws .EmptyClusterControlPlaneAwsServicesAuthentication
939
939
}
940
940
objArr := o .([]interface {})
941
- if len (objArr ) == 0 {
941
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
942
942
return containeraws .EmptyClusterControlPlaneAwsServicesAuthentication
943
943
}
944
944
obj := objArr [0 ].(map [string ]interface {})
@@ -966,7 +966,7 @@ func expandContainerAwsClusterControlPlaneConfigEncryption(o interface{}) *conta
966
966
return containeraws .EmptyClusterControlPlaneConfigEncryption
967
967
}
968
968
objArr := o .([]interface {})
969
- if len (objArr ) == 0 {
969
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
970
970
return containeraws .EmptyClusterControlPlaneConfigEncryption
971
971
}
972
972
obj := objArr [0 ].(map [string ]interface {})
@@ -992,7 +992,7 @@ func expandContainerAwsClusterControlPlaneDatabaseEncryption(o interface{}) *con
992
992
return containeraws .EmptyClusterControlPlaneDatabaseEncryption
993
993
}
994
994
objArr := o .([]interface {})
995
- if len (objArr ) == 0 {
995
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
996
996
return containeraws .EmptyClusterControlPlaneDatabaseEncryption
997
997
}
998
998
obj := objArr [0 ].(map [string ]interface {})
@@ -1018,7 +1018,7 @@ func expandContainerAwsClusterControlPlaneMainVolume(o interface{}) *containeraw
1018
1018
return nil
1019
1019
}
1020
1020
objArr := o .([]interface {})
1021
- if len (objArr ) == 0 {
1021
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1022
1022
return nil
1023
1023
}
1024
1024
obj := objArr [0 ].(map [string ]interface {})
@@ -1050,7 +1050,7 @@ func expandContainerAwsClusterControlPlaneProxyConfig(o interface{}) *containera
1050
1050
return containeraws .EmptyClusterControlPlaneProxyConfig
1051
1051
}
1052
1052
objArr := o .([]interface {})
1053
- if len (objArr ) == 0 {
1053
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1054
1054
return containeraws .EmptyClusterControlPlaneProxyConfig
1055
1055
}
1056
1056
obj := objArr [0 ].(map [string ]interface {})
@@ -1078,7 +1078,7 @@ func expandContainerAwsClusterControlPlaneRootVolume(o interface{}) *containeraw
1078
1078
return nil
1079
1079
}
1080
1080
objArr := o .([]interface {})
1081
- if len (objArr ) == 0 {
1081
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1082
1082
return nil
1083
1083
}
1084
1084
obj := objArr [0 ].(map [string ]interface {})
@@ -1110,7 +1110,7 @@ func expandContainerAwsClusterControlPlaneSshConfig(o interface{}) *containeraws
1110
1110
return containeraws .EmptyClusterControlPlaneSshConfig
1111
1111
}
1112
1112
objArr := o .([]interface {})
1113
- if len (objArr ) == 0 {
1113
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1114
1114
return containeraws .EmptyClusterControlPlaneSshConfig
1115
1115
}
1116
1116
obj := objArr [0 ].(map [string ]interface {})
@@ -1136,7 +1136,7 @@ func expandContainerAwsClusterFleet(o interface{}) *containeraws.ClusterFleet {
1136
1136
return containeraws .EmptyClusterFleet
1137
1137
}
1138
1138
objArr := o .([]interface {})
1139
- if len (objArr ) == 0 {
1139
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1140
1140
return containeraws .EmptyClusterFleet
1141
1141
}
1142
1142
obj := objArr [0 ].(map [string ]interface {})
@@ -1163,7 +1163,7 @@ func expandContainerAwsClusterNetworking(o interface{}) *containeraws.ClusterNet
1163
1163
return containeraws .EmptyClusterNetworking
1164
1164
}
1165
1165
objArr := o .([]interface {})
1166
- if len (objArr ) == 0 {
1166
+ if len (objArr ) == 0 || objArr [ 0 ] == nil {
1167
1167
return containeraws .EmptyClusterNetworking
1168
1168
}
1169
1169
obj := objArr [0 ].(map [string ]interface {})
0 commit comments