- String error = validator.apply(Simantics.getSession(), componentType, propertyInfo.resource, newValue);
- if (error != null)
- return;
+ if (validator != null) {
+ String error = validator.apply(Simantics.getSession(), componentType, propertyInfo.resource, newValue);
+ if (error != null)
+ return;
+ }