@@ -107,7 +107,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
107
107
108
108
dialogHelper . promptDialog ( 'choose-component-dialog' , { availableComponentNames } ) . then ( result => {
109
109
// no result indicates operation was cancelled
110
- if ( result ? .componentName ) {
110
+ if ( result && result . componentName ) {
111
111
this . project . vzApplication . components . addNewItem ( {
112
112
name : result . componentName ,
113
113
ingressTraitEnable : false ,
@@ -214,7 +214,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
214
214
215
215
dialogHelper . promptDialog ( 'choose-secrets-dialog' , args ) . then ( result => {
216
216
// no result indicates operation was cancelled
217
- if ( result ? .secretNames ) {
217
+ if ( result && result . secretNames ) {
218
218
this . project . vzApplication . secrets . value = result . secretNames ;
219
219
this . populateObservableSecrets ( ) ;
220
220
}
@@ -236,7 +236,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
236
236
} ;
237
237
dialogHelper . promptDialog ( 'choose-secret-dialog' , args ) . then ( result => {
238
238
// no result indicates operation was cancelled
239
- if ( result ? .secretName ) {
239
+ if ( result && result . secretName ) {
240
240
selectedSecretNameObservable ( result . secretName ) ;
241
241
}
242
242
} ) ;
@@ -257,7 +257,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
257
257
} ;
258
258
dialogHelper . promptDialog ( 'choose-secret-dialog' , args ) . then ( result => {
259
259
// no result indicates operation was cancelled
260
- if ( result ? .secretName ) {
260
+ if ( result && result . secretName ) {
261
261
selectedSecretNameObservable ( result . secretName ) ;
262
262
}
263
263
} ) ;
@@ -343,7 +343,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
343
343
} ;
344
344
dialogHelper . promptDialog ( 'choose-deployment-dialog' , args ) . then ( result => {
345
345
// no result indicates operation was cancelled
346
- if ( result ? .deploymentName ) {
346
+ if ( result && result . deploymentName ) {
347
347
selectedDeploymentNameObservable ( result . deploymentName ) ;
348
348
}
349
349
} ) ;
@@ -393,7 +393,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
393
393
394
394
dialogHelper . promptDialog ( 'choose-clusters-dialog' , { selectedClusterNames, availableClusterNames } ) . then ( result => {
395
395
// no result indicates operation was cancelled
396
- if ( result ? .clusterNames ) {
396
+ if ( result && result . clusterNames ) {
397
397
this . project . vzApplication . placementClusters . value = result . clusterNames ;
398
398
this . populateObservableClusters ( ) ;
399
399
}
@@ -499,7 +499,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
499
499
const observableArray = this . componentObservable ( component , 'ingressTraitRules' ) ;
500
500
const newRule = { uid : utils . getShortUuid ( ) } ;
501
501
dialogHelper . promptDialog ( 'vz-ingress-trait-rule-edit-dialog' , newRule ) . then ( result => {
502
- if ( result ? .rule ) {
502
+ if ( result && result . rule ) {
503
503
observableArray . push ( result . rule ) ;
504
504
}
505
505
} ) ;
@@ -513,7 +513,7 @@ function (project, accUtils, utils, ko, i18n, BufferingDataProvider, ArrayDataPr
513
513
const ruleOptions = { ...rule } ;
514
514
515
515
dialogHelper . promptDialog ( 'vz-ingress-trait-rule-edit-dialog' , ruleOptions ) . then ( result => {
516
- if ( result ? .rule ) {
516
+ if ( result && result . rule ) {
517
517
const mergedRule = this . mergeRule ( rule , result . rule ) ;
518
518
observableArray . replace ( rule , mergedRule ) ;
519
519
}
0 commit comments