diff --git a/src/main/java/biz/netcentric/filevault/validator/DateProperty.java b/src/main/java/biz/netcentric/filevault/validator/DateProperty.java index 668df5d..9c6f492 100644 --- a/src/main/java/biz/netcentric/filevault/validator/DateProperty.java +++ b/src/main/java/biz/netcentric/filevault/validator/DateProperty.java @@ -105,7 +105,7 @@ Optional> extractDate(@NotNull DocViewNode2 node, Pr } else { // check for auto-created property Collection types = new HashSet<>(); - node.getPrimaryType().map(t -> types.add(t)); + node.getPrimaryType().ifPresent(types::add); types.addAll(node.getMixinTypes()); if (propertyName.getAutoCreatedTypes().stream().anyMatch(types::contains)) { dateAndLabel = new SimpleEntry<>(Calendar.getInstance(), "auto created " + propertyName.getName().toString());