amend FIXME to IMPL.refa because it's too much efford for now

This commit is contained in:
Michael Hoennig 2024-06-14 09:59:18 +02:00
parent 6c30109bad
commit d7b7d91392
2 changed files with 2 additions and 8 deletions

View File

@ -42,7 +42,7 @@ public class HsBookingItemEntityValidator extends HsEntityValidator<HsBookingIte
).filter(Objects::nonNull).toList();
}
// FIXME: convert into generic shape like multi-options validator
// TODO.refa: convert into generic shape like multi-options validator
private static String validateMaxTotalValue(
final HsBookingItemEntity bookingItem,
final ValidatableProperty<?> propDef) {

View File

@ -22,7 +22,7 @@ public abstract class HsEntityValidator<E> {
protected static List<String> enrich(final String prefix, final List<String> messages) {
return messages.stream()
// FIXME: this is a bit hacky, I need to find the right place to add the prefix
// TODO:refa: this is a bit hacky, I need to find the right place to add the prefix
.map(message -> message.startsWith("'") ? message : ("'" + prefix + "." + message))
.toList();
}
@ -52,12 +52,6 @@ public abstract class HsEntityValidator<E> {
return result;
}
protected List<String> validateParentEntities(final HsBookingItemEntity bookingItem) {
return bookingItem.getParentItem() != null ?
HsBookingItemEntityValidatorRegistry.doValidate(bookingItem.getParentItem()) :
emptyList();
}
@SafeVarargs
protected static List<String> sequentiallyValidate(final Supplier<List<String>>... validators) {
return new ArrayList<>(stream(validators)