@@ -121,8 +121,7 @@ export default {
121121 api (' listDedicatedZones' , {
122122 zoneid: this .resource .id
123123 }).then (response => {
124- if (response .listdedicatedzonesresponse .dedicatedzone &&
125- response .listdedicatedzonesresponse .dedicatedzone .length > 0 ) {
124+ if (response? .listdedicatedzonesresponse ? .dedicatedzone ? .length > 0 ) {
126125 this .dedicatedDomainId = response .listdedicatedzonesresponse .dedicatedzone [0 ].domainid
127126 this .dedicatedAccountId = response .listdedicatedzonesresponse .dedicatedzone [0 ].accountid
128127 }
@@ -134,8 +133,7 @@ export default {
134133 api (' listDedicatedPods' , {
135134 podid: this .resource .id
136135 }).then (response => {
137- if (response .listdedicatedpodsresponse .dedicatedpod &&
138- response .listdedicatedpodsresponse .dedicatedpod .length > 0 ) {
136+ if (response? .listdedicatedpodsresponse ? .dedicatedpod ? .length > 0 ) {
139137 this .dedicatedDomainId = response .listdedicatedpodsresponse .dedicatedpod [0 ].domainid
140138 this .dedicatedAccountId = response .listdedicatedpodsresponse .dedicatedpod [0 ].accountid
141139 }
@@ -147,8 +145,7 @@ export default {
147145 api (' listDedicatedClusters' , {
148146 clusterid: this .resource .id
149147 }).then (response => {
150- if (response .listdedicatedclustersresponse .dedicatedcluster &&
151- response .listdedicatedclustersresponse .dedicatedcluster .length > 0 ) {
148+ if (response? .listdedicatedclustersresponse ? .dedicatedcluster ? .length > 0 ) {
152149 this .dedicatedDomainId = response .listdedicatedclustersresponse .dedicatedcluster [0 ].domainid
153150 this .dedicatedAccountId = response .listdedicatedclustersresponse .dedicatedcluster [0 ].accountid
154151 }
@@ -160,8 +157,7 @@ export default {
160157 api (' listDedicatedHosts' , {
161158 hostid: this .resource .id
162159 }).then (response => {
163- if (response .listdedicatedhostsresponse .dedicatedhost &&
164- response .listdedicatedhostsresponse .dedicatedhost .length > 0 ) {
160+ if (response? .listdedicatedhostsresponse ? .dedicatedhost ? .length > 0 ) {
165161 this .dedicatedDomainId = response .listdedicatedhostsresponse .dedicatedhost [0 ].domainid
166162 this .dedicatedAccountId = response .listdedicatedhostsresponse .dedicatedhost [0 ].accountid
167163 }
0 commit comments