aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-ui
diff options
context:
space:
mode:
authorandre.schmid <andre.schmid@est.tech>2022-05-20 19:14:00 +0100
committerMichael Morris <michael.morris@est.tech>2022-05-23 10:49:14 +0000
commitf82f57944a6cf0151cf611e938acda0cb6ea9d65 (patch)
treec78520906e9bf9dc2ef959a48f3c3dc73bd085f6 /catalog-ui
parentf7fac88023c4f99775e9d5ae008b7141d42fbf3d (diff)
Fix exception while loading VF "General" page
The exception is thrown when accessing a VF General page from a VF that is not associated to a CSAR file (Imported from CSAR file). The code is trying to access the CSAR file that does not exist. Change-Id: I0df34e75911e4a912f50ff8993637952e32d48c6 Issue-ID: SDC-4013 Signed-off-by: andre.schmid <andre.schmid@est.tech>
Diffstat (limited to 'catalog-ui')
-rw-r--r--catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts b/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts
index 043f4dd859..6b0d49029a 100644
--- a/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts
+++ b/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts
@@ -216,7 +216,9 @@ export class GeneralViewModel {
if(this.$stateParams.componentCsar && this.$scope.component.lifecycleState === 'NOT_CERTIFIED_CHECKIN' && !this.$scope.isCreateMode()) {
this.$scope.importedToscaBrowseFileText = this.$scope.originComponent.name + ' (' + (this.$scope.originComponent as Resource).csarVersion + ')';
} else {
- this.$scope.importedToscaBrowseFileText = onboardCsarFilesMap[csarUUID][csarVersion];
+ if (onboardCsarFilesMap && onboardCsarFilesMap[csarUUID]) {
+ this.$scope.importedToscaBrowseFileText = onboardCsarFilesMap[csarUUID][csarVersion];
+ }
}
}
}