Skip to content

Commit 96858db

Browse files
Pearl1594rp-
authored andcommitted
ui: Prevent reset of port-forward rules on cancelling a form (#4981)
* ui: Prevent reset of port-forward rules on cancelling a form * add check for undefined value
1 parent e29044c commit 96858db

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

ui/src/views/network/LoadBalancing.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,7 @@ export default {
554554
vpcid: this.resource.vpcid
555555
}).then(json => {
556556
this.tiers.data = json.listnetworksresponse.network || []
557-
this.selectedTier = this.tiers.data && this.tiers.data[0].id ? this.tiers.data[0].id : null
557+
this.selectedTier = this.tiers.data?.[0]?.id ? this.tiers.data[0].id : null
558558
this.$forceUpdate()
559559
}).catch(error => {
560560
this.$notifyError(error)

ui/src/views/network/PortForwarding.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -503,7 +503,6 @@ export default {
503503
this.addVmModalNicLoading = false
504504
this.nics = []
505505
this.resetTagInputs()
506-
this.resetAllRules()
507506
},
508507
openTagsModal (id) {
509508
this.tagsModalLoading = true

0 commit comments

Comments
 (0)