Damans227 commented on code in PR #14399:
URL: https://github.com/apache/cloudstack/pull/14399#discussion_r4270424342


##########
ui/src/views/network/CreateIsolatedNetworkForm.vue:
##########
@@ -566,24 +574,30 @@ export default {
       if (!isAdmin()) { // normal user is not aware of the VLANs in the 
system, so normal user is not allowed to create network with network offerings 
whose specifyvlan = true
         params.specifyvlan = false
       }
-      if (forVpc !== null) {
+      if (forVpc !== undefined && forVpc !== null) {
         params.forvpc = forVpc
       }
       this.networkOfferings = []
       this.selectedNetworkOffering = {}
       getAPI('listNetworkOfferings', params).then(json => {
-        this.networkOfferings = 
json.listnetworkofferingsresponse.networkoffering || []
-        this.networkOfferings = this.networkOfferings.filter(offering => 
offering.fornsx === this.selectedZone.isnsxenabled)
-        if (!this.selectedZone.routedmodeenabled) {
+        const offerings = json?.listnetworkofferingsresponse?.networkoffering 
|| []

Review Comment:
   looks like #13503 already fixed the crash on the isolated tab for 4.22 and 
main. does it still show request failed on main without this change?



##########
ui/src/views/network/CreateSharedNetworkForm.vue:
##########
@@ -800,8 +800,10 @@ export default {
       this.handleNetworkOfferingChange(null)
       this.networkOfferings = []
       getAPI('listNetworkOfferings', params).then(json => {
-        this.networkOfferings = 
json.listnetworkofferingsresponse.networkoffering || []
+        const offerings = json?.listnetworkofferingsresponse?.networkoffering 
|| []

Review Comment:
   the shared tab already handles an empty list here in 4.22.1.0. which request 
fails on that tab in the browser network tab?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to