Merge branch 'v2.0'
authorKIRAN KASHALKAR <kiran.kashalkar@riftio.com>
Fri, 5 May 2017 03:36:09 +0000 (23:36 -0400)
committerKIRAN KASHALKAR <kiran.kashalkar@riftio.com>
Fri, 5 May 2017 03:36:09 +0000 (23:36 -0400)
skyquake/plugins/composer/src/src/components/EditDescriptorModelProperties.js
skyquake/plugins/launchpad/src/launchpad_card/launchpadCardCloudAccount.jsx

index c923ede..ad2bf3d 100644 (file)
@@ -538,7 +538,7 @@ export default function EditDescriptorModelProperties(props) {
                                selectedOptionValue = utils.resolvePath(container.model, ['uiState.choice', pathToChoice, 'selected'].join('.'));
                        } else {
                                property.properties.map(function(p) {
-                                       let pname = p.properties[0].name;
+                                       let pname = p.properties[0] && p.properties[0].name;
                                        if(container.model.hasOwnProperty(pname)) {
                                                utils.assignPathValue(container.model, ['uiState.choice', pathToChoice, 'selected'].join('.'), [p.name, pname].join('.'));
                                        }
@@ -747,7 +747,7 @@ export default function EditDescriptorModelProperties(props) {
                        value = utils.resolvePath(container.model, ['uiState.choice'].concat(path, 'selected').join('.'));
                        if(!value) {
                                property.properties.map(function(p) {
-                                       let pname = p.properties[0].name;
+                                       let pname = p.properties[0] && p.properties[0].name;
                                        if(container.model.hasOwnProperty(pname)) {
                                                value = container.model[pname];
                                        }
index 1856dda..39397ff 100644 (file)
@@ -36,7 +36,7 @@ export default class LaunchpadCardCloudAccount extends React.Component {
         (<li key="nsr"><h3>NSR: {this.props.nsr['cloud-account']}</h3></li>)
       )
     }
-    this.props.nsr['vnfrs'].map(function(v,i) {
+    this.props.nsr['vnfrs'] && this.props.nsr['vnfrs'].map(function(v,i) {
       if(v.hasOwnProperty('cloud-account')) {
         status.push(
           (<li key={i}><h3>VNFR {v['short-name']}: {v['cloud-account']}</h3></li>)