Fix 'in_range constraints missing from TOSCA template'-bug
[sdc.git] / catalog-ui / src / app / ng2 / pages / properties-assignment / constraints / constraints.component.ts
index 1e0eb4f..525bf88 100644 (file)
@@ -52,7 +52,7 @@ export class ConstraintsComponent implements OnInit {
       }
     }
     this.constraints = new Array();
-    if(changes.propertyConstraints.currentValue) {
+    if (changes.propertyConstraints && changes.propertyConstraints.currentValue) {
       changes.propertyConstraints.currentValue.forEach((constraint: any) => {
         this.constraints.push(this.getConstraintFromPropertyBEModel(constraint));
       });
@@ -341,4 +341,4 @@ export const ConstraintTypesMapping = {
 export interface Constraint {
   type:ConstraintTypes,
   value:any
-}
\ No newline at end of file
+}